unix_msg: Use struct initializers
[kamenim/samba-autobuild/.git] / source3 / smbd / avahi_register.c
index 1903b0ef9642bfc39b6b45526d5290aa0d363f81..368168d41dc4a8c07f192786f03cec472caf9504 100644 (file)
@@ -19,6 +19,7 @@
  */
 
 #include "includes.h"
+#include "smbd/smbd.h"
 
 #include <avahi-client/client.h>
 #include <avahi-client/publish.h>
@@ -87,7 +88,7 @@ static void avahi_client_callback(AvahiClient *c, AvahiClientState status,
                }
                if (avahi_entry_group_add_service(
                            state->entry_group, AVAHI_IF_UNSPEC,
-                           AVAHI_PROTO_UNSPEC, 0, global_myname(),
+                           AVAHI_PROTO_UNSPEC, 0, lp_netbios_name(),
                            "_smb._tcp", NULL, NULL, state->port, NULL) < 0) {
                        error = avahi_client_errno(c);
                        DEBUG(10, ("avahi_entry_group_add_service failed: "