case AVAHI_SERVER_COLLISION: {
char *n;
+ avahi_set_proc_title("%s: collision", argv0);
+
static_service_remove_from_server();
static_hosts_remove_from_server();
-
remove_dns_server_entry_groups();
-
+
n = avahi_alternative_host_name(avahi_server_get_host_name(s));
avahi_log_warn("Host name conflict, retrying with <%s>", n);
avahi_server_set_host_name(s, n);
avahi_free(n);
- avahi_set_proc_title("%s: collision", argv0);
-
break;
}
break;
case AVAHI_SERVER_REGISTERING:
- avahi_set_proc_title("%s: registering [%s]", argv0, avahi_server_get_host_name_fqdn(s));
+ avahi_set_proc_title("%s: registering [%s]", argv0, avahi_server_get_host_name_fqdn(s));
+
+ static_service_remove_from_server();
+ static_hosts_remove_from_server();
+ remove_dns_server_entry_groups();
+
+ break;
case AVAHI_SERVER_INVALID:
break;