From 96a7b2607cd30e2b8d2c870fa0cf0a35a166d703 Mon Sep 17 00:00:00 2001 From: bp-sawyers Date: Sat, 3 May 2008 13:49:33 +0000 Subject: [PATCH] Temporarily commented out the use of Thread so it would build git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@1269 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-client-2.0/bin/prsync | 12 ++++++------ xCAT-client-2.0/bin/pscp | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/xCAT-client-2.0/bin/prsync b/xCAT-client-2.0/bin/prsync index af898cfe8..1c072c87e 100755 --- a/xCAT-client-2.0/bin/prsync +++ b/xCAT-client-2.0/bin/prsync @@ -14,7 +14,7 @@ use Data::Dumper; use IO::Handle; use IO::Select; use xCAT::Utils; -use Threads qw(yield); +#use Threads qw(yield); use Getopt::Long; use POSIX qw(:signal_h :errno_h :sys_wait_h); my $interface; @@ -72,16 +72,16 @@ close($client); my $children = 0; my $inputs = new IO::Select; $SIG{CHLD} = \&reaper; -sub reaper { - while (($pid = waitpid(-1,WNOHANG)) > 0) { - $children--; +sub reaper { + while (($pid = waitpid(-1,WNOHANG)) > 0) { + $children--; } if ($children and $pid == -1) { #for whatever reason, rsync processes slip by frequently $children = 0; } $SIG{CHLD} = \&reaper; } - + if ($interface) { foreach (@nodes) { @@ -120,7 +120,7 @@ sub processoutput { #This way, one arbiter handles output, no interrupting chomp($line); print $nodehdl{$readyh}.": ".$line."\n"; } - yield; + #yield; return $rc; } sub scpnode { diff --git a/xCAT-client-2.0/bin/pscp b/xCAT-client-2.0/bin/pscp index 189e57960..55b74d03a 100755 --- a/xCAT-client-2.0/bin/pscp +++ b/xCAT-client-2.0/bin/pscp @@ -13,7 +13,7 @@ if ($^O =~ /^linux/i) { use Data::Dumper; use IO::Handle; use IO::Select; -use Threads qw(yield); +#use Threads qw(yield); use xCAT::Utils; use Getopt::Long; use POSIX qw(:signal_h :errno_h :sys_wait_h); @@ -109,7 +109,7 @@ sub processoutput { #This way, one arbiter handles output, no interrupting chomp($line); print $nodehdl{$readyh}.": ".$line."\n"; } - yield; + #yield; return $rc; } sub scpnode {