Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 19 lines (14 sloc) 0.643 kb
768aa00 @ggreer Use pcre_study. This should make regex matching faster. Throw util funct...
authored
1 #ifndef UTIL_H
2 #define UTIL_H
3
b3e8409 @ggreer Detect whether or not the query is a regex. Fix a bug in case-insensitiv...
authored
4 void generate_skip_lookup(const char *find, size_t f_len, size_t skip_lookup[], int case_sensitive);
7efae7e @ggreer Cleanup. Kill the old strstr functions.
authored
5 char* boyer_moore_strnstr(const char *s, const char *find, size_t s_len, size_t f_len, size_t skip_lookup[]);
64d2ea1 @ggreer Add case-insensitive Boyer-Moore-Horspool strstr.
authored
6 char* boyer_moore_strncasestr(const char *s, const char *find, size_t s_len, size_t f_len, size_t skip_lookup[]);
30ee9bc @ggreer More progress. Still buggy though.
authored
7
768aa00 @ggreer Use pcre_study. This should make regex matching faster. Throw util funct...
authored
8 int is_binary(const void* buf, const int buf_len);
d5d8ed4 @ggreer Stub out is_regex(). People aren't going to use --literal all the time..
authored
9 int is_regex(const char* query, const int query_len);
7efae7e @ggreer Cleanup. Kill the old strstr functions.
authored
10
bc4d900 @ggreer Use OS strlcat/strlcpy if they exist.
authored
11 #ifndef HAVE_STRLCAT
12 size_t strlcat(char *dest, const char *src, size_t size);
13 #endif
14 #ifndef HAVE_STRLCPY
15 size_t strlcpy(char *dest, const char *src, size_t size);
16 #endif
768aa00 @ggreer Use pcre_study. This should make regex matching faster. Throw util funct...
authored
17
18 #endif
Something went wrong with that request. Please try again.