mirror of
https://github.com/inspircd/inspircd.git
synced 2025-03-10 11:09:04 -04:00
Fix irc_char_traits::find to behave correctly when the character is not found. Bug #823, patch by Phoenix Fledgeling
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11291 e03df62e-2008-0410-955e-edbf42e46eb7
This commit is contained in:
parent
18ecd877f5
commit
29ee8ab0ad
@ -154,7 +154,7 @@ const char* irc::irc_char_traits::find(const char* s1, int n, char c)
|
||||
{
|
||||
while(n-- > 0 && national_case_insensitive_map[(unsigned char)*s1] != national_case_insensitive_map[(unsigned char)c])
|
||||
s1++;
|
||||
return s1;
|
||||
return (n >= 0) ? s1 : NULL;
|
||||
}
|
||||
|
||||
irc::tokenstream::tokenstream(const std::string &source) : tokens(source), last_pushed(false)
|
||||
|
Loading…
x
Reference in New Issue
Block a user