Escape to prevent command expansion

This commit is contained in:
Ilia Rostovtsev
2020-10-07 20:17:21 +03:00
parent 1f50a3a4e6
commit 20f947e7e5

View File

@ -622,7 +622,12 @@ else {
sub escapestr
{
local $rv = $_[0];
# Prevent escaping query
$rv =~ s/'/''/g;
# Prevent escaping command
$rv =~ s/"/\\"/g;
return $rv;
}