]> git.ipfire.org Git - thirdparty/unbound.git/commitdiff
fix libevent-1.3 and older bug
authorWouter Wijngaards <wouter@nlnetlabs.nl>
Thu, 15 Jan 2009 13:48:03 +0000 (13:48 +0000)
committerWouter Wijngaards <wouter@nlnetlabs.nl>
Thu, 15 Jan 2009 13:48:03 +0000 (13:48 +0000)
git-svn-id: file:///svn/unbound/trunk@1441 be551aaa-1e26-0410-a405-d3ace91eadb9

doc/Changelog
util/netevent.c

index e6bdd8bb536b6a7ac41b67eb8356a5eeda4dffb0..1172fe6a19c953e4d704ee6c4f2dc9b5ae8d6d2f 100644 (file)
@@ -2,6 +2,7 @@
        - bug #229: fixup configure checks for compilation with Solaris 
          Sun cc compiler, ./configure CC=/opt/SUNWspro/bin/cc
        - fixup suncc warnings.
+       - fix bug where unbound could crash using libevent 1.3 and older.
 
 14 January 2009: Wouter
        - 1.2.1 feature: negative caching for failed queries.
index efaa82d94ac615219f0bca5e1b74f3e2323abfbd..8cee50da3830f47ebb8fe18274bfbd4bbce45c8e 100644 (file)
@@ -169,12 +169,14 @@ comm_base_create(int sigs)
                return NULL;
        }
        comm_base_now(b);
+       /* avoid event_get_method call which causes crashes even when
+        * not printing, because its result is passed */
        verbose(VERB_ALGO, "libevent %s uses %s method.", 
                event_get_version(), 
 #ifdef HAVE_EVENT_BASE_GET_METHOD
                event_base_get_method(b->eb->base)
 #else
-               event_get_method()
+               "not_obtainable"
 #endif
        );
        return b;