Merge pull request #416 from c79/patch-1

Fix hostname showing directory when no hostname
This commit is contained in:
oblique
2019-11-05 09:07:32 +02:00
committed by GitHub

View File

@ -869,7 +869,7 @@ print_client() {
if [[ -f $CONFDIR/dnsmasq.leases ]]; then
line=$(grep " $mac " $CONFDIR/dnsmasq.leases | tail -n 1)
ipaddr=$(echo $line | cut -d' ' -f3)
hostname=$(echo $line | cut -d' ' -f4)
hostname=$(echo "$line" | cut -d' ' -f4)
fi
[[ -z "$ipaddr" ]] && ipaddr="*"