diff options
author | Andrew Dolgov <[email protected]> | 2010-11-29 21:29:58 +0300 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2010-11-29 21:29:58 +0300 |
commit | d769a0f75a42323a38cce3637629a4750443e67c (patch) | |
tree | b2a44c0be28f5b7123710198af4106cce0406462 | |
parent | 741b60909ffcf67475c5ea7f66c6e870584d2b59 (diff) |
fix session ip checking
-rw-r--r-- | functions.php | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/functions.php b/functions.php index 7c12d538d..175817892 100644 --- a/functions.php +++ b/functions.php @@ -1917,9 +1917,11 @@ break; }; - if ($check_ip && strpos($_SERVER['REMOTE_ADDR'], $check_ip) !== 0) - $_SESSION["login_error_msg"] = - __("Session failed to validate (incorrect IP)"); + if ($check_ip && strpos($_SERVER['REMOTE_ADDR'], $check_ip) !== 0) { + $_SESSION["login_error_msg"] = + __("Session failed to validate (incorrect IP)"); + return false; + } if ($_SESSION["ref_schema_version"] != get_schema_version($link, true)) return false; |