diff options
author | Andrew Bartlett <abartlet@samba.org> | 2011-06-24 16:26:23 +1000 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2011-06-24 16:26:23 +1000 |
commit | 6da26870e0ae5acd6ff49a30ec2f6886b44d095e (patch) | |
tree | 850c71039563c16a5d563c47e7ba2ab645baf198 /source3/utils/nmblookup.c | |
parent | 6925a799d04c6fa59dd2ddef1f5510f9bb7d17d1 (diff) | |
parent | 2610c05b5b95cc7036b3d6dfb894c6cfbdb68483 (diff) | |
download | samba-6da26870e0ae5acd6ff49a30ec2f6886b44d095e.tar.gz samba-6da26870e0ae5acd6ff49a30ec2f6886b44d095e.tar.bz2 samba-6da26870e0ae5acd6ff49a30ec2f6886b44d095e.zip |
Merge 2610c05b5b95cc7036b3d6dfb894c6cfbdb68483 as Samba-4.0alpha16
Diffstat (limited to 'source3/utils/nmblookup.c')
-rw-r--r-- | source3/utils/nmblookup.c | 24 |
1 files changed, 3 insertions, 21 deletions
diff --git a/source3/utils/nmblookup.c b/source3/utils/nmblookup.c index f8545401e6..73db278e36 100644 --- a/source3/utils/nmblookup.c +++ b/source3/utils/nmblookup.c @@ -168,27 +168,9 @@ static bool query_one(const char *lookup, unsigned int lookup_type) &bcast_addr, talloc_tos(), &ip_list, &count, &flags); } else { - const struct in_addr *bcast; - for (j=iface_count() - 1; - !ip_list && j >= 0; - j--) { - char addr[INET6_ADDRSTRLEN]; - struct sockaddr_storage bcast_ss; - - bcast = iface_n_bcast_v4(j); - if (!bcast) { - continue; - } - in_addr_to_sockaddr_storage(&bcast_ss, *bcast); - print_sockaddr(addr, sizeof(addr), &bcast_ss); - d_printf("querying %s on %s\n", - lookup, addr); - status = name_query(lookup,lookup_type, - use_bcast, - use_bcast?True:recursion_desired, - &bcast_ss, talloc_tos(), - &ip_list, &count, &flags); - } + status = name_resolve_bcast( + lookup, lookup_type, + talloc_tos(), &ip_list, &count); } if (!NT_STATUS_IS_OK(status)) { |