diff options
author | Jim P <jim@pingle.org> | 2012-06-18 18:10:57 -0700 |
---|---|---|
committer | Jim P <jim@pingle.org> | 2012-06-18 18:10:57 -0700 |
commit | d599735c6daaea920fe48cb22780834c4ab1d542 (patch) | |
tree | 14e65d7031864a10e82ec7421a0397e5f3d38bc3 | |
parent | 4777e65b38baf3e3ed1d812d04e8b5be5446ca5b (diff) | |
parent | a4531082e8d8dbcc98b97f1fd6fb030ab4b90f96 (diff) | |
download | pfsense-packages-d599735c6daaea920fe48cb22780834c4ab1d542.tar.gz pfsense-packages-d599735c6daaea920fe48cb22780834c4ab1d542.tar.bz2 pfsense-packages-d599735c6daaea920fe48cb22780834c4ab1d542.zip |
Merge pull request #258 from ccesario/master
Change eregi() to preg_match() function
-rw-r--r-- | config/lightsquid/lightsquid.inc | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/config/lightsquid/lightsquid.inc b/config/lightsquid/lightsquid.inc index 0b98cfe3..bddb0bb3 100644 --- a/config/lightsquid/lightsquid.inc +++ b/config/lightsquid/lightsquid.inc @@ -215,10 +215,10 @@ function lightsquid_resync() { foreach ($lsconf_var as $key => $val) { for($i = 0; $i < count($lsconf); $i++) { $s = trim($lsconf[$i]); - $e_key = "^[$]" . $key . "[ ]*[=]+"; -# update_log("Regular: eregi(\"$e_key," . "'$s')"); // debug regular template - if (eregi($e_key, $s)) { -# update_log("Regular PASSED: eregi(\"$e_key," . "'$s')"); // debug regular template + $e_key = "/^[$]" . $key . "[ ]*[=]+/i"; +# update_log("Regular: preg_match(\"$e_key," . "'$s')"); // debug regular template + if (preg_match($e_key, $s)) { +# update_log("Regular PASSED: preg_match(\"$e_key," . "'$s')"); // debug regular template $lsconf[$i] = '$' . "$key = $val;"; update_log("Update config: $key=$val"); } |