diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2018-11-12 12:57:24 +0000 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2018-11-12 12:57:24 +0000 |
commit | 093dd1190db7062e5c7f53c8bfb2af5a8e9faa5c (patch) | |
tree | 8a26ac62aea8b9636722485c51d05924f3f9a75e /contrib/aho-corasick/acism.h | |
parent | 29e1d556d9f0f7061aabfe93122cafb5450c75c3 (diff) | |
download | rspamd-093dd1190db7062e5c7f53c8bfb2af5a8e9faa5c.tar.gz rspamd-093dd1190db7062e5c7f53c8bfb2af5a8e9faa5c.zip |
[Fix] Fix actrie implementation (sync from upstream), fixed OOB read
Diffstat (limited to 'contrib/aho-corasick/acism.h')
-rw-r--r-- | contrib/aho-corasick/acism.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/contrib/aho-corasick/acism.h b/contrib/aho-corasick/acism.h index d942fd413..b5a3b1a5c 100644 --- a/contrib/aho-corasick/acism.h +++ b/contrib/aho-corasick/acism.h @@ -25,9 +25,11 @@ // "acism" uses MEMREF {ptr,len} bytevec structs for "string" args, // rather than NUL-terminated "C" strings. -typedef struct { char const *ptr; size_t len; } ac_trie_pat_t; +typedef struct ac_trie_pat_s { char const *ptr; size_t len; } ac_trie_pat_t; typedef struct acism ac_trie_t; +typedef struct acism ACISM; +typedef struct ac_trie_pat_s MEMREF; ac_trie_t* acism_create(ac_trie_pat_t const *strv, int nstrs); void acism_destroy(ac_trie_t*); |