]> git.meshlink.io Git - catta/blobdiff - examples/client-publish-service.c
add new client state AVAHI_CLIENT_FAILURE
[catta] / examples / client-publish-service.c
index 7013156fd5cbdc3e25a781de18b281a796feb880..2f126c173090e33b5d9dde77658e28b48f3bcd04 100644 (file)
@@ -157,6 +157,13 @@ static void client_callback(AvahiClient *c, AvahiClientState state, AVAHI_GCC_UN
 
             break;
 
+        case AVAHI_CLIENT_FAILURE:
+            
+            fprintf(stderr, "Client failure: %s\n", avahi_strerror(avahi_client_errno(c)));
+            avahi_simple_poll_quit(simple_poll);
+            
+            break;
+
         case AVAHI_CLIENT_S_REGISTERING:
             ;
     }