Fix correctness of string search
The lookup for the skip value needs to be based upon the lowercase version of the current byte.
This commit is contained in:
parent
77f0963d00
commit
876500a259
1 changed files with 1 additions and 1 deletions
|
@ -118,7 +118,7 @@ size_t search_string(const std::string& text, const std::string& pattern) {
|
|||
return t+p;
|
||||
}
|
||||
}
|
||||
t += skip[text[t+p]];
|
||||
t += skip[std::tolower(text[t+p])];
|
||||
}
|
||||
|
||||
return std::string::npos;
|
||||
|
|
Loading…
Reference in a new issue