From 10336a71c8e2f3f41bd182cf880c1002c0238a5c Mon Sep 17 00:00:00 2001 From: zhanx Date: Mon, 11 May 2009 10:51:16 +0000 Subject: [PATCH] Fix rscan bug 2769237: rscan command includes duplicate bpa stanza entries git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@3333 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- perl-xCAT/xCAT/PPCscan.pm | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/perl-xCAT/xCAT/PPCscan.pm b/perl-xCAT/xCAT/PPCscan.pm index 91b37a84e..4c92b31cc 100644 --- a/perl-xCAT/xCAT/PPCscan.pm +++ b/perl-xCAT/xCAT/PPCscan.pm @@ -254,8 +254,12 @@ sub enumerate { if ( defined($host) ) { $fname = $host; } - push @values, join( ",", - "bpa",$fname,$id,$model,$serial,$server,$prof,$bpa,"$ipa $ipb"); + my $bpastr = join( ",","bpa",$fname,$id,$model,$serial,$server,$prof,$bpa,"$ipa $ipb"); + if ( !grep /^\Q$bpastr\E$/, @values) + { + push @values, join( ",", + "bpa",$fname,$id,$model,$serial,$server,$prof,$bpa,"$ipa $ipb"); + } } ##################################### # Save CEC information