]> git.ipfire.org Git - thirdparty/rspamd.git/commitdiff
Do not delete uninitialized events.
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Thu, 30 Jul 2015 17:51:20 +0000 (18:51 +0100)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Thu, 30 Jul 2015 17:51:20 +0000 (18:51 +0100)
src/libutil/http.c

index df44ec9b2a8e83592ace62773940c16fe4e8fa7a..db7ea83fa5af3022bf92128bc31c438e38bfba8c 100644 (file)
@@ -1602,7 +1602,10 @@ rspamd_http_connection_write_message (struct rspamd_http_connection *conn,
                }
        }
 
-       event_del (&priv->ev);
+       if (base != NULL && event_get_base (&priv->ev) == base) {
+               event_del (&priv->ev);
+       }
+
        event_set (&priv->ev, fd, EV_WRITE, rspamd_http_event_handler, conn);
 
        if (base != NULL) {