From: Aryeh Gregor Date: Wed, 22 Nov 2006 23:32:21 +0000 (+0000) Subject: More bugs! Why did I only spot these after commit >:| X-Git-Tag: 1.31.0-rc.0~55112 X-Git-Url: https://git.cyclocoop.org/%28%28?a=commitdiff_plain;h=a6931256ec082ec850addfd1abf535fce30aab17;p=lhc%2Fweb%2Fwiklou.git More bugs! Why did I only spot these after commit >:| --- diff --git a/includes/Block.php b/includes/Block.php index 404e574fc2..8dbf127f40 100644 --- a/includes/Block.php +++ b/includes/Block.php @@ -504,8 +504,8 @@ class Block wfDebug("Checking $wlEntry\n"); # Is the IP in this range? - if (IP::isAddressInRange( $autoblockip, $wlEntry )) { - wfDebug("IP $autoblockip matches $wlEntry, not autoblocking\n"); + if (IP::isAddressInRange( $ip, $wlEntry )) { + wfDebug("IP $ip matches $wlEntry, not autoblocking\n"); return true; #This /SHOULD/ introduce a dummy block - but # I don't know a safe way to do so. -werdna } diff --git a/includes/IP.php b/includes/IP.php index d6b87043da..6251ad8e6f 100644 --- a/includes/IP.php +++ b/includes/IP.php @@ -218,8 +218,8 @@ class IP { } /** - * Determine if a given integer IPv4 address is in a given range - * @param int $addr + * Determine if a given IPv4 address is in a given range + * @param string $addr Dotted quad * @param string $range (CIDR, hyphenated dotted-quad, or single dotted-quad) * @return bool Whether or not the given address is in the given range. Returns false on error. */