diff --git a/src/check-symfile.pl b/src/check-symfile.pl index 454fed3260..c0b7ec7573 100755 --- a/src/check-symfile.pl +++ b/src/check-symfile.pl @@ -5,9 +5,11 @@ die "syntax: $0 SYMFILE ELFLIB(S)" unless int(@ARGV) >= 2; my $symfile = shift @ARGV; my @elflibs = @ARGV; -my @wantsyms; +my %wantsyms; my %gotsyms; +my $ret = 0; + open SYMFILE, $symfile or die "cannot read $symfile: $!"; while () { @@ -21,7 +23,12 @@ while () { die "malformed line $_" unless /^\s*(\S+);$/; - push @wantsyms, $1; + if (exists $wantsyms{$1}) { + print STDERR "Symbol $1 is listed twice\n"; + $ret = 1; + } else { + $wantsyms{$1} = 1; + } } close SYMFILE; @@ -37,8 +44,6 @@ foreach my $elflib (@elflibs) { close NM; } -my $ret = 0; - foreach my $sym (@wantsyms) { next if exists $gotsyms{$sym}; diff --git a/src/libvirt_private.syms b/src/libvirt_private.syms index abfee47afc..9971befdd2 100644 --- a/src/libvirt_private.syms +++ b/src/libvirt_private.syms @@ -1178,8 +1178,6 @@ virDirCreate; virDoubleToStr; virEnumFromString; virEnumToString; -virEventAddHandle; -virEventRemoveHandle; virFileAbsPath; virFileAccessibleAs; virFileBuildPath;