mirror of
https://github.com/pfsense/pfsense.git
synced 2025-10-26 11:38:35 +00:00
Enable php_check_syntax() checking of eval'd scripts and report an error on console if one occurs
This commit is contained in:
parent
0790a5851d
commit
9ba517a2d3
@ -155,12 +155,14 @@ function filter_configure() {
|
||||
if(stristr($file, ".sh") == true) {
|
||||
mwexec("/usr/local/pkg/pf/" . $file . " start");
|
||||
} else {
|
||||
//if(php_check_syntax($text, $error_message) == false)
|
||||
if(php_check_syntax($text, $error_message) == false)
|
||||
if($g['booting'] == true)
|
||||
echo "\t{$file}... ";
|
||||
eval($text);
|
||||
if($g['booting'] == true)
|
||||
echo "done.\n";
|
||||
else
|
||||
echo "Error deteceted in {$file}: {$error_message}\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user