From: Lennart Poettering Date: Wed, 21 Jun 2006 23:30:47 +0000 (+0000) Subject: fix segfault when destructing multicast lookup objects X-Git-Url: https://git.meshlink.io/?a=commitdiff_plain;h=cbc25b664f659450190e255e840bb84ab9d35668;p=catta fix segfault when destructing multicast lookup objects git-svn-id: file:///home/lennart/svn/public/avahi/trunk@1225 941a03a8-eaeb-0310-b9a0-b1bbd8fe43fe --- diff --git a/avahi-core/browse.c b/avahi-core/browse.c index dd4fe3c..16d8954 100644 --- a/avahi-core/browse.c +++ b/avahi-core/browse.c @@ -195,7 +195,6 @@ static void browser_cancel(AvahiSRecordBrowser *b) { } } - static void lookup_wide_area_callback( AvahiWideAreaLookupEngine *e, AvahiBrowserEvent event, @@ -208,6 +207,7 @@ static void lookup_wide_area_callback( assert(e); assert(l); + assert(l->ref >= 1); b = l->record_browser; @@ -422,6 +422,7 @@ static void lookup_handle_cname(AvahiSRBLookup *l, AvahiIfIndex interface, Avahi l->cname_lookups = avahi_rlist_prepend(l->cname_lookups, lookup_ref(n)); lookup_go(n); + lookup_unref(n); } static void lookup_drop_cname(AvahiSRBLookup *l, AvahiIfIndex interface, AvahiProtocol protocol, AvahiLookupFlags flags, AvahiRecord *r) {