From 27ce38b618025682465e369fd19699ae849d8cd2 Mon Sep 17 00:00:00 2001 From: Nick Mathewson Date: Wed, 1 Jun 2011 17:27:28 -0400 Subject: [PATCH] Avoid a segfault when all methods are disabled or broken --- event.c | 1 + 1 file changed, 1 insertion(+) diff --git a/event.c b/event.c index 41c7d8f4..99d2eec5 100644 --- a/event.c +++ b/event.c @@ -603,6 +603,7 @@ event_base_new_with_config(const struct event_config *cfg) if (base->evbase == NULL) { event_warnx("%s: no event mechanism available", __func__); + base->evsel = NULL; event_base_free(base); return NULL; }