Commit 21031190 authored by Dries's avatar Dries

- Patch #221364 by chx: removed PHP 4.3 workaround. Oh, yeah.

parent 5bdc79db
......@@ -91,18 +91,7 @@ function sess_write($key, $value) {
*/
function sess_regenerate() {
$old_session_id = session_id();
// We code around http://bugs.php.net/bug.php?id=32802 by destroying
// the session cookie by setting expiration in the past (a negative
// value). This issue only arises in PHP versions before 4.4.0,
// regardless of the Drupal configuration.
// TODO: remove this when we require at least PHP 4.4.0
if (isset($_COOKIE[session_name()])) {
setcookie(session_name(), '', time() - 42000, '/');
}
session_regenerate_id();
db_query("UPDATE {sessions} SET sid = '%s' WHERE sid = '%s'", session_id(), $old_session_id);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment