mirror of
https://github.com/webmin/webmin.git
synced 2025-07-23 00:30:33 +00:00
Fixed eval of in modules with -
This commit is contained in:
@ -232,7 +232,9 @@ while(1) {
|
|||||||
print STDERR "fastrpc: eval $arg->{'module'} $arg->{'code'}\n" if ($gconfig{'rpcdebug'});
|
print STDERR "fastrpc: eval $arg->{'module'} $arg->{'code'}\n" if ($gconfig{'rpcdebug'});
|
||||||
local $rv;
|
local $rv;
|
||||||
if ($arg->{'module'}) {
|
if ($arg->{'module'}) {
|
||||||
$rv = eval "package $arg->{'module'};\n".
|
local $pkg = $arg->{'module'};
|
||||||
|
$pkg =~ s/[^A-Za-z0-9]/_/g;
|
||||||
|
$rv = eval "package $pkg;\n".
|
||||||
$arg->{'code'}."\n";
|
$arg->{'code'}."\n";
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
Reference in New Issue
Block a user