diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2013-09-24 15:53:51 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2013-09-24 15:53:51 +0100 |
commit | daa897e1a17ca5e631df144365594e4527c8d4ea (patch) | |
tree | 9e2666b5fe5670a9d4f8a8d03f3f7e2b5a59cada /src | |
parent | d838161a48eee9651ffdc5a73367769e466d6948 (diff) | |
download | rspamd-daa897e1a17ca5e631df144365594e4527c8d4ea.tar.gz rspamd-daa897e1a17ca5e631df144365594e4527c8d4ea.zip |
Fix libfetch related code.
Diffstat (limited to 'src')
-rw-r--r-- | src/rcl/rcl_util.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/rcl/rcl_util.c b/src/rcl/rcl_util.c index b5aabaf89..8a42e40a4 100644 --- a/src/rcl/rcl_util.c +++ b/src/rcl/rcl_util.c @@ -280,7 +280,6 @@ rspamd_cl_fetch_url (const guchar *url, guchar **buf, gsize *buflen, GError **er struct url *fetch_url; struct url_stat us; FILE *in; - guchar *buf; fetch_url = fetchParseURL (url); if (fetch_url == NULL) { @@ -297,7 +296,7 @@ rspamd_cl_fetch_url (const guchar *url, guchar **buf, gsize *buflen, GError **er *buflen = us.size; *buf = g_malloc (*buflen); - if (buf == NULL) { + if (*buf == NULL) { g_set_error (err, RCL_ERROR, RSPAMD_CL_EIO, "cannot allocate buffer for URL %s: %s", url, strerror (errno)); fclose (in); |