aboutsummaryrefslogtreecommitdiffstats
path: root/src/ragel/content_disposition_parser.rl
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2020-09-02 11:22:56 +0100
committerVsevolod Stakhov <vsevolod@highsecure.ru>2020-09-02 11:22:56 +0100
commit76b8e42e1cf49a03b057030541867f098dccac5b (patch)
tree931d82f4337fb228c67ab0a094bd606ddc1dd229 /src/ragel/content_disposition_parser.rl
parentd6ae9647d2d5ad8ad291c8d462acecbc3c74dd13 (diff)
downloadrspamd-76b8e42e1cf49a03b057030541867f098dccac5b.tar.gz
rspamd-76b8e42e1cf49a03b057030541867f098dccac5b.zip
[Fix] Use unsigned char and better support of utf8 in ragel parser
Diffstat (limited to 'src/ragel/content_disposition_parser.rl')
-rw-r--r--src/ragel/content_disposition_parser.rl3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/ragel/content_disposition_parser.rl b/src/ragel/content_disposition_parser.rl
index e17f900a1..cdef4db46 100644
--- a/src/ragel/content_disposition_parser.rl
+++ b/src/ragel/content_disposition_parser.rl
@@ -1,5 +1,6 @@
%%{
machine content_type_parser;
+ alphtype unsigned char;
action Disposition_Start {
}
@@ -101,7 +102,7 @@
gboolean
rspamd_content_disposition_parser (const char *data, size_t len, struct rspamd_content_disposition *cd, rspamd_mempool_t *pool)
{
- const char *p = data, *pe = data + len, *eof, *qstart = NULL, *qend = NULL,
+ const unsigned char *p = data, *pe = data + len, *eof, *qstart = NULL, *qend = NULL,
*pname_start = NULL, *pname_end = NULL, *pvalue_start = NULL, *pvalue_end = NULL;
int cs, *stack = NULL;
gsize top = 0;