diff options
author | Herb Lewis <herb@samba.org> | 1998-03-25 00:20:52 +0000 |
---|---|---|
committer | Herb Lewis <herb@samba.org> | 1998-03-25 00:20:52 +0000 |
commit | 6cba6919ebf65691d2fb6a880da038a6dff9f6b1 (patch) | |
tree | 238461c53590e3eb8e6fbeddd2ac273ef6bb7cfa | |
parent | 607c64fadbf8c33459444466630f676800cba5ee (diff) | |
download | samba-6cba6919ebf65691d2fb6a880da038a6dff9f6b1.tar.gz samba-6cba6919ebf65691d2fb6a880da038a6dff9f6b1.tar.xz samba-6cba6919ebf65691d2fb6a880da038a6dff9f6b1.zip |
added check for one more error case
-rwxr-xr-x | packaging/SGI/findsmb | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/packaging/SGI/findsmb b/packaging/SGI/findsmb index 82aeb28dab3..4cb3c80a428 100755 --- a/packaging/SGI/findsmb +++ b/packaging/SGI/findsmb @@ -65,9 +65,17 @@ foreach $ip (@ipaddrs) # loop through each IP address found @name = grep(/<00>/,@nmblookup); $_ = @name[0]; - if ($_) { # we have a netbios name - /(\S+)/; - $name = $1; + if ($_) { # we have a netbios name + if (/GROUP/) { # is it a group name + ($name, $aliases, $type, $length, @addresses) = + gethostbyaddr(pack('C4',split('\.',$ip)),2); + if (! $name) { # could not get name + $name = "unknown nis name"; + } + } else { + /(\S+)/; + $name = $1; + } # do an smbclient command on the netbios name. |