-Fix problem where dispatch targets get tripped up over the empty _xcatdest XML

element.  This fix leaves the _xcatdest element intact as some plugins detect preprocessing on it, but ensures the daemon realizes the nature of the element


git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@1989 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
jbjohnso 2008-08-07 14:43:58 +00:00
parent 32ff984b67
commit 52621ee31c

View File

@ -903,6 +903,9 @@ sub dispatch_request {
}
undef $SIG{CHLD};
$dispatch_parentfd = $parfd;
if (ref($_->{'_xcatdest'}) eq 'ARRAY') {
$_->{'_xcatdest'} = $_->{'_xcatdest'}->[0];
}
if ($_->{'_xcatdest'} and thishostisnot($_->{'_xcatdest'})) {
$ENV{XCATHOST} = ( $_->{'_xcatdest'} =~ /:/ ? $_->{'_xcatdest'} : $_->{'_xcatdest'}.":3001" );
$$progname.=": connection to ".$ENV{XCATHOST};