diff options
Diffstat (limited to 'includes')
-rw-r--r-- | includes/bootstrap.inc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/includes/bootstrap.inc b/includes/bootstrap.inc index 90f16f818..d07cd7f43 100644 --- a/includes/bootstrap.inc +++ b/includes/bootstrap.inc @@ -1236,7 +1236,8 @@ function ip_address($reset = FALSE) { if (!empty($reverse_proxy_addresses) && in_array($ip_address, $reverse_proxy_addresses, TRUE)) { // If there are several arguments, we need to check the most // recently added one, i.e. the last one. - $ip_address = array_pop(explode(',', $_SERVER['HTTP_X_FORWARDED_FOR'])); + $ip_address_parts = explode(',', $_SERVER['HTTP_X_FORWARDED_FOR']); + $ip_address = array_pop($ip_address_parts); } } |