mirror of
https://github.com/anope/anope.git
synced 2026-06-25 17:26:37 +02:00
Make sockaddrs/cidr not throw on invalid ips to give us an easier/cheaper way to test for a valid IP
This commit is contained in:
+1
-1
@@ -82,7 +82,7 @@ int ci::ci_char_traits::compare(const char *str1, const char *str2, size_t n)
|
||||
|
||||
const char *ci::ci_char_traits::find(const char *s1, int n, char c)
|
||||
{
|
||||
while (n-- > 0 && case_map_upper[static_cast<unsigned char>(*s1)] != static_cast<unsigned char>(c))
|
||||
while (n-- > 0 && case_map_upper[static_cast<unsigned char>(*s1)] != case_map_upper[static_cast<unsigned char>(c)])
|
||||
++s1;
|
||||
return n >= 0 ? s1 : NULL;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user