int thread_running;
pthread_mutex_t mutex;
-
+
void *context;
DNSServiceBrowseReply service_browser_callback;
DNSServiceResolveReply service_resolver_callback;
if (sdref->simple_poll)
avahi_simple_poll_free(sdref->simple_poll);
-
if (sdref->thread_fd >= 0)
close(sdref->thread_fd);
AVAHI_WARN_LINKAGE;
- sdref_ref(sdref);
-
ASSERT_SUCCESS(pthread_mutex_lock(&sdref->mutex));
+
+ sdref_ref(sdref);
/* Cleanup notification socket */
if (read_command(sdref->main_fd) != COMMAND_POLL_DONE)
finish:
- ASSERT_SUCCESS(pthread_mutex_unlock(&sdref->mutex));
-
sdref_unref(sdref);
+
+ ASSERT_SUCCESS(pthread_mutex_unlock(&sdref->mutex));
return ret;
}