2
0
mirror of https://github.com/xcat2/xcat-core.git synced 2025-05-30 09:36:41 +00:00

Merge pull request #223 from hu-weihua/cmdlog

Fix bug#203 xdsh could not recognize single quote mark
This commit is contained in:
yangsong 2015-09-28 11:25:21 +08:00
commit 2d2e2f8608

View File

@ -2503,8 +2503,9 @@ sub service_connection {
if(exists($req->{arg})){
foreach my $arg (@{$req->{arg}}) {
if($arg =~ /[^A-Za-z0-9.-]/){
$arg =~ s/'/'\\''/g;
$cmdlog_alllog .= "'".$arg."' ";
my $tmparg = $arg;
$tmparg =~ s/'/'\\''/g;
$cmdlog_alllog .= "'".$tmparg."' ";
}else{
$cmdlog_alllog .= $arg." ";
}