- Fix the "weird bug" with different serialized file under cli/cgi or apache sapi

Important Notice:
*always* use 'wb' to write file, sapi cli and cgi force the default to be binary, apache does not.
This commit is contained in:
Pierre Joye 2003-05-27 23:31:56 +00:00
parent 94136f0ccd
commit 400e5c0b66

View File

@ -404,7 +404,7 @@ class PEAR_Registry extends PEAR
if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
return $e;
}
$fp = $this->_openPackageFile($package, 'w');
$fp = $this->_openPackageFile($package, 'wb');
if ($fp === null) {
$this->_unlock();
return false;