struct subnet_record *remote_broadcast_subnet = NULL;
struct subnet_record *wins_server_subnet = NULL;
-extern uint16 samba_nb_type; /* Samba's NetBIOS name type. */
+extern uint16_t samba_nb_type; /* Samba's NetBIOS name type. */
/****************************************************************************
Add a subnet into the list.
void close_subnet(struct subnet_record *subrec)
{
+ if (subrec->nmb_sock != -1) {
+ close(subrec->nmb_sock);
+ subrec->nmb_sock = -1;
+ }
+ if (subrec->nmb_bcast != -1) {
+ close(subrec->nmb_bcast);
+ subrec->nmb_bcast = -1;
+ }
if (subrec->dgram_sock != -1) {
close(subrec->dgram_sock);
subrec->dgram_sock = -1;
}
- if (subrec->nmb_sock != -1) {
- close(subrec->nmb_sock);
- subrec->nmb_sock = -1;
+ if (subrec->dgram_bcast != -1) {
+ close(subrec->dgram_bcast);
+ subrec->dgram_bcast = -1;
}
DLIST_REMOVE(subnetlist, subrec);
/* Only count IPv4, non-loopback interfaces. */
if (iface_count_v4_nl() == 0) {
- DEBUG(0,("create_subnets: No local IPv4 non-loopback interfaces !\n"));
- DEBUG(0,("create_subnets: Waiting for an interface to appear ...\n"));
+ daemon_status("nmbd",
+ "No local IPv4 non-loopback interfaces "
+ "available, waiting for interface ...");
+ DEBUG(0,("NOTE: NetBIOS name resolution is not supported for "
+ "Internet Protocol Version 6 (IPv6).\n"));
}
/* We only count IPv4, non-loopback interfaces here. */