mirror of
https://github.com/NoelFB/blah.git
synced 2024-11-25 16:18:57 +08:00
fix to String::contains
This commit is contained in:
parent
36b0d266b1
commit
a5f9701ce6
|
@ -191,7 +191,7 @@ bool BaseString::contains(const char* cstr, bool ignore_case) const
|
|||
return false;
|
||||
|
||||
const char* ptr = s_ptr();
|
||||
const char* end = s_ptr() + length() - len;
|
||||
const char* end = s_ptr() + length() - len + 1;
|
||||
auto compare = (ignore_case ? &blah_compare_ignore_case : &blah_compare_with_case);
|
||||
|
||||
while (ptr < end)
|
||||
|
|
Loading…
Reference in New Issue
Block a user