diff --git a/xCAT-server/sbin/xcatd b/xCAT-server/sbin/xcatd index b99e1a9de..840e6a7a4 100755 --- a/xCAT-server/sbin/xcatd +++ b/xCAT-server/sbin/xcatd @@ -2201,6 +2201,7 @@ sub get_request { $flags |= O_NONBLOCK; #we want sysread to bail on us, select seems to be evil to us still.. fcntl($sock,F_SETFL,$flags); my $bytesread; + if (!($line) ) { $line = ''; } do { $bytesread=sysread($sock,$line,65536,length($line)) } while ($bytesread); if (length($line)==0) { if (not defined $bytesread and ($! == EAGAIN or $! == ECHILD)) { next; } # ECHILD makes no sense, but some platform does it