summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStig Bakken <ssb@php.net>2002-05-28 00:31:04 +0000
committerStig Bakken <ssb@php.net>2002-05-28 00:31:04 +0000
commit52a00c9a0c4c486bb01307abebf8af777ace191b (patch)
tree081f170f06b8b07cb2f6cd4539ecd76953eacd00
parent7917b3f25314e40b9dc2f4982a937518b15128a8 (diff)
downloadphp-git-52a00c9a0c4c486bb01307abebf8af777ace191b.tar.gz
* disable magic_quotes_runtime (what a broken concept!!) while
reading config files
-rw-r--r--pear/PEAR/Config.php4
1 files changed, 4 insertions, 0 deletions
diff --git a/pear/PEAR/Config.php b/pear/PEAR/Config.php
index 146ceca3e9..26917fa79a 100644
--- a/pear/PEAR/Config.php
+++ b/pear/PEAR/Config.php
@@ -399,8 +399,12 @@ class PEAR_Config extends PEAR
if (!$fp) {
return $this->raiseError("PEAR_Config::readConfigFile fopen('$file','r') failed");
}
+ $old_ini = ini_get("magic_quotes_runtime");
+ ini_set("magic_quotes_runtime", false);
$size = filesize($file);
$contents = fread($fp, $size);
+ fclose($fp);
+ ini_set("magic_quotes_runtime", $old_ini);
$version = '0.1';
if (preg_match('/^#PEAR_Config\s+(\S+)\s+/si', $contents, $matches)) {
$version = $matches[1];