]> source.dussan.org Git - rspamd.git/commitdiff
Fix parsing of query arguments.
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Wed, 7 Oct 2015 16:16:53 +0000 (17:16 +0100)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Wed, 7 Oct 2015 16:16:53 +0000 (17:16 +0100)
src/libutil/http.c

index eedc9c4512993cc7eb6fdf9a69fa1fc5426983e3..6c9617ae57c5c0cb316805e763e03b5fb2f0abc8 100644 (file)
@@ -2465,7 +2465,7 @@ rspamd_http_message_parse_query (struct rspamd_http_message *msg)
                                        if ((*p == '&' || p == end) && p >= c) {
                                                g_assert (key != NULL);
                                                if (p > c) {
-                                                       value = rspamd_fstring_new_init ("", 0);
+                                                       value = rspamd_fstring_new_init (c, p - c);
                                                        value_tok = g_slice_alloc (sizeof (*value_tok));
                                                        value_tok->begin = value->str;
                                                        value_tok->len = rspamd_decode_url (value->str,