aboutsummaryrefslogtreecommitdiffstats
path: root/src/map.c
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@rambler-co.ru>2009-09-15 18:42:05 +0400
committerVsevolod Stakhov <vsevolod@rambler-co.ru>2009-09-15 18:42:05 +0400
commit6b57031f55ef73619b763c98eadb1dbf82494eac (patch)
tree8a749d0b5c0ac6c331363a7a3ba871666c2f148c /src/map.c
parente03d0749928abdff045de0bd2eeb21c5989a94c4 (diff)
downloadrspamd-6b57031f55ef73619b763c98eadb1dbf82494eac.tar.gz
rspamd-6b57031f55ef73619b763c98eadb1dbf82494eac.zip
* Add lua plugin for checking received headers
* Some tunes to lua API * Fix bug with http maps * Optimize installation and make custom prefix for configs
Diffstat (limited to 'src/map.c')
-rw-r--r--src/map.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/map.c b/src/map.c
index d250970b1..f878e59b1 100644
--- a/src/map.c
+++ b/src/map.c
@@ -189,7 +189,7 @@ static int
read_chunk_header (u_char *buf, size_t len, struct http_map_data *data)
{
u_char chunkbuf[32], *p, *c;
- int skip;
+ int skip = 0;
p = chunkbuf;
c = buf;
@@ -280,6 +280,9 @@ read_http_common (struct rspamd_map *map, struct http_map_data *data, struct htt
memmove (buf, remain, rlen);
r = rlen;
}
+ if (r <= 0) {
+ return TRUE;
+ }
if (reply->parser_state == 6) {
if (reply->code != 200 && reply->code != 304) {
msg_err ("read_http: got error reply from server %s, %d", data->host, reply->code);