From daa86ed28a8cd6b657f7e02c33c01d2139e9e1fb Mon Sep 17 00:00:00 2001 From: Vsevolod Stakhov Date: Fri, 8 May 2015 13:56:53 +0100 Subject: [PATCH] Fix headers addition. --- src/libutil/http.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libutil/http.c b/src/libutil/http.c index 1b0e31ac2..f64c9ba6a 100644 --- a/src/libutil/http.c +++ b/src/libutil/http.c @@ -1504,8 +1504,8 @@ rspamd_http_message_add_header (struct rspamd_http_message *msg, hdr = g_slice_alloc (sizeof (struct rspamd_http_header)); nlen = strlen (name); vlen = strlen (value); - hdr->combined = g_string_sized_new (nlen + vlen + 2); - rspamd_printf_gstring (hdr->combined, "%s: %s"); + hdr->combined = g_string_sized_new (nlen + vlen + 4); + rspamd_printf_gstring (hdr->combined, "%s: %s\r\n", name, value); hdr->value = g_slice_alloc (sizeof (GString)); hdr->name = g_slice_alloc (sizeof (GString)); hdr->name->str = hdr->combined->str; -- 2.39.5