Skip to content

Commit a773a43

Browse files
committed
fix the IP problems : always return 0.0.0.0 (this crashes for example with IPv6)
1 parent 683b279 commit a773a43

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

class/art/functions.user.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
function mod_getIP($asString = false)
2727
{
2828
// Gets the proxy ip sent by the user
29-
$proxy_ip = '';
29+
/*$proxy_ip = '';
3030
if (!empty($_SERVER["HTTP_X_FORWARDED_FOR"])) {
3131
$proxy_ip = $_SERVER["HTTP_X_FORWARDED_FOR"];
3232
} else if (!empty($_SERVER["HTTP_X_FORWARDED"])) {
@@ -53,8 +53,8 @@ function mod_getIP($asString = false)
5353
}
5454
5555
$the_IP = ($asString) ? $the_IP : ip2long($the_IP);
56-
57-
return $the_IP;
56+
*/
57+
return '0.0.0.0';
5858
}
5959

6060
function &mod_getUnameFromIds( $uid, $usereal = false, $linked = false )

0 commit comments

Comments
 (0)