diff options
author | Richard Sharpe <sharpe@samba.org> | 2004-04-16 03:57:30 +0000 |
---|---|---|
committer | Richard Sharpe <sharpe@samba.org> | 2004-04-16 03:57:30 +0000 |
commit | 1f71693777006047a53da3282bb6e1eadf257a1e (patch) | |
tree | 9a7ffcd40309842c699676ed19efb8db10a2b167 /source/utils | |
parent | 1f12d3298942bb45dd617ffb373ec8bb0466f805 (diff) | |
download | samba-1f71693777006047a53da3282bb6e1eadf257a1e.tar.gz |
r248: Add support for printing out the MAC address on nmblookup.
Diffstat (limited to 'source/utils')
-rw-r--r-- | source/utils/nmblookup.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/source/utils/nmblookup.c b/source/utils/nmblookup.c index 3c5a22841ea..7285712c0b7 100644 --- a/source/utils/nmblookup.c +++ b/source/utils/nmblookup.c @@ -102,11 +102,12 @@ static void do_node_status(int fd, const char *name, int type, struct in_addr ip struct nmb_name nname; int count, i, j; struct node_status *status; + struct node_status_extra extra; fstring cleanname; d_printf("Looking up status of %s\n",inet_ntoa(ip)); make_nmb_name(&nname, name, type); - status = node_status_query(fd,&nname,ip, &count); + status = node_status_query(fd,&nname,ip, &count, &extra); if (status) { for (i=0;i<count;i++) { pull_ascii_fstring(cleanname, status[i].name); @@ -119,6 +120,9 @@ static void do_node_status(int fd, const char *name, int type, struct in_addr ip } SAFE_FREE(status); } + d_printf("\n\tMAC Address = %02X-%02X-%02X-%02X-%02X-%02X\n", + extra.mac_addr[0], extra.mac_addr[1], extra.mac_addr[2], + extra.mac_addr[3], extra.mac_addr[4], extra.mac_addr[5]); d_printf("\n"); } |