-Sanitize responses from plugins if they throw non-printable characters that are invalid in XML parsing
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@4655 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
parent
403f1ee57d
commit
1ddd71f7f0
@ -1198,7 +1198,10 @@ sub convey_response {
|
||||
build_response($resp);
|
||||
return;
|
||||
}
|
||||
print $parent_fd XMLout($resp,KeyAttr=>[], NoAttr=>1,RootName=>'xcatresponse');
|
||||
$resp = XMLout($resp,KeyAttr=>[], NoAttr=>1,RootName=>'xcatresponse');
|
||||
#sanitize the response, to avoid being killed by non-printable bytes
|
||||
$resp =~ tr/\011-\177/?/c;
|
||||
print $parent_fd $resp;
|
||||
yield; #parent must get timeslice anyway before an ack could possibly return
|
||||
my $parsel = new IO::Select;
|
||||
$parsel->add($parent_fd);
|
||||
|
Loading…
Reference in New Issue
Block a user