* (bug 2384) Fix typo in regex for IP address checking
authorBrion Vibber <brion@users.mediawiki.org>
Sat, 11 Jun 2005 09:26:28 +0000 (09:26 +0000)
committerBrion Vibber <brion@users.mediawiki.org>
Sat, 11 Jun 2005 09:26:28 +0000 (09:26 +0000)
RELEASE-NOTES
includes/User.php

index 34ef2bf..9f38cad 100644 (file)
@@ -276,6 +276,7 @@ Various bugfixes, small features, and a few experimental things:
 * (bug 2368) Avoid fatally breaking PHP 4.1.2 in a debug line
 * (bug 2367) Insert correct redirect link record on page move
 * (bug 2372) Fix rendering of empty-title inline interwiki links
+* (bug 2384) Fix typo in regex for IP address checking
 
 
 === Caveats ===
index 1038801..485e5f6 100644 (file)
@@ -137,7 +137,7 @@ class User {
         * @return bool
         */
        function isIP( $name ) {
-               return preg_match("/^\d{1,3}\.\d{1,3}.\d{1,3}\.\d{1,3}$/",$name);
+               return preg_match("/^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}$/",$name);
                /*return preg_match("/^
                        (?:[01]?\d{1,2}|2(:?[0-4]\d|5[0-5]))\.
                        (?:[01]?\d{1,2}|2(:?[0-4]\d|5[0-5]))\.