]> git.meshlink.io Git - catta/blobdiff - avahi-compat-howl/compat.c
* add new entry group state AVAHI_ENTRY_GROUP_FAILURE
[catta] / avahi-compat-howl / compat.c
index d9a1bdab113792d4ea23bfc12aef3c51070ceb04..8e8dd06f1819ab7b3f672506136d361e9967a6fd 100644 (file)
 #include <avahi-common/simple-watch.h>
 #include <avahi-common/error.h>
 #include <avahi-common/llist.h>
+
 #include <avahi-client/client.h>
+#include <avahi-client/publish.h>
+#include <avahi-client/lookup.h>
 
 #include "howl.h"
 #include "warn.h"
@@ -691,6 +694,7 @@ static void reg_client_callback(oid_data *data, AvahiClientState state) {
         return;
     
     switch (state) {
+        case AVAHI_CLIENT_S_FAILURE:
         case AVAHI_CLIENT_DISCONNECTED:
             reg_report_status(data, SW_DISCOVERY_PUBLISH_INVALID);
             break;
@@ -742,6 +746,11 @@ static void reg_entry_group_callback(AvahiEntryGroup *g, AvahiEntryGroupState st
         case AVAHI_ENTRY_GROUP_UNCOMMITED:
             /* Ignore */
             break;
+
+        case AVAHI_ENTRY_GROUP_FAILURE:
+            reg_report_status(data, SW_DISCOVERY_PUBLISH_INVALID);
+            break;
+            
     }
 }