]> source.dussan.org Git - rspamd.git/commitdiff
Fix memory and descriptors leak in controller.
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Wed, 10 Sep 2014 11:52:53 +0000 (12:52 +0100)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Wed, 10 Sep 2014 11:52:53 +0000 (12:52 +0100)
src/plugins/fuzzy_check.c

index 0b50111edb1932976dfc4cb33e06135a13f377c5..a5a7041fd344c672e1b30740b99ffd3d12704bed 100644 (file)
@@ -724,12 +724,13 @@ fuzzy_learn_callback (gint fd, short what, void *arg)
 err:
        msg_err ("got error in IO with server %s, %d, %s",
                session->server->name, errno, strerror (errno));
+
+ok:
        rspamd_http_connection_unref (session->http_entry->conn);
        rspamd_task_free (session->task, TRUE);
        event_del (&session->ev);
        close (session->fd);
 
-ok:
        if (--(*(session->saved)) == 0) {
                if (*(session->err) != NULL) {
                        rspamd_controller_send_error (session->http_entry,