* EndpointPermission.cs: Fix IsSubsetof(hostname) so that the regression
authorJonathan Pryor <jpryor@novell.com>
Thu, 20 Jan 2005 22:06:48 +0000 (22:06 -0000)
committerJonathan Pryor <jpryor@novell.com>
Thu, 20 Jan 2005 22:06:48 +0000 (22:06 -0000)
    tests work.  In particular, IsSubsetOf ("12.13.*.*", "12.13.14.*") failed
    because 14 wasn't a subset of * (which it is).  Fix: if part1 is we
    continue to the next portion.

svn path=/trunk/mcs/; revision=39282

mcs/class/System/System.Net/ChangeLog
mcs/class/System/System.Net/EndpointPermission.cs

index fe24ebf4f1d35d341aba8dca06c44e0b519011b5..46caa36d56937e37927c994e49a08c0e4357dd59 100644 (file)
@@ -1,3 +1,10 @@
+2005-01-20  Jonathan Pryor  <jonpryor@vt.edu>
+
+       * EndpointPermission.cs: Fix IsSubsetof(hostname) so that the regression 
+         tests work.  In particular, IsSubsetOf ("12.13.*.*", "12.13.14.*") failed
+         because 14 wasn't a subset of * (which it is).  Fix: if part1 is we 
+         continue to the next portion.
+
 2005-01-20  Jonathan Pryor  <jonpryor@vt.edu>
 
        * IPAddress.cs (ParseIPV4): Fix so that the regression tests work.  In
index 434ba912fde79834108fce0da75389622f00b1d4..92ff6941a82f07a8f18f10d805c35715568d5ff6 100644 (file)
@@ -157,6 +157,8 @@ namespace System.Net
                                int part2 = ToNumber (h2 [i]);\r
                                if (part2 == -1)\r
                                        return false;                           \r
+                               if (part1 == 256)
+                                       continue;
                                if (part1 != part2 && part2 != 256)\r
                                        return false;\r
                        }\r