Commit ea3a4cfa authored by Sebastian Ramacher's avatar Sebastian Ramacher
Browse files

Case-insensitive search

parent 71421a7c
......@@ -34,6 +34,7 @@ defines = [
'-DVERSION_MINOR=@0@'.format(version_array[1]),
'-DVERSION_REV=@0@'.format(version_array[2]),
'-D_DEFAULT_SOURCE',
'-D_GNU_SOURCE',
]
# compile flags
......
......@@ -146,7 +146,7 @@ djvu_page_text_search(djvu_page_text_t* page_text, const char* text)
int search_length = strlen(text);
char* tmp = page_text->content;
while ((tmp = strstr(tmp, text)) != NULL) {
while ((tmp = strcasestr(tmp, text)) != NULL) {
int start_pointer = tmp - page_text->content;
int end_pointer = start_pointer + search_length - 1;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment