]> xenbits.xensource.com Git - libvirt.git/commitdiff
Fix possible undefined value in check-symsorting.pl
authorDaniel P. Berrange <berrange@redhat.com>
Mon, 22 Apr 2013 17:23:28 +0000 (18:23 +0100)
committerDaniel P. Berrange <berrange@redhat.com>
Wed, 8 May 2013 09:21:01 +0000 (10:21 +0100)
It is possible for $line to be undefined at first used, if
the symfile doesn't have a section prefix (which is the case
for auto-generated symfiles).

Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
src/check-symsorting.pl

index c523c34b21a58583b6c0b81f41b4a450ed7c3a72..f360dfb69f6e514e7f35dd6bf1dc81490543e3c9 100755 (executable)
@@ -11,7 +11,7 @@ my $lastgroup = undef;
 foreach my $symfile (@ARGV) {
     open SYMFILE, $symfile or die "cannot read $symfile: $!";
 
-    my $line;
+    my $line = 0;
     my $groupfile = "";
     my @group;