Handle nmblookup error codes
@@ -29,14 +29,18 @@ for m in `cat /etc/smbmounts.conf | grep -v ^#`; do
# The try to resolve using nmblookup
if [ "$IP" == "" ]; then
+ nmblookup $HOST > /tmp/$$
+ if [ "$?" == "0" ]; then
IP=`nmblookup $HOST|awk 'END{print $1}'`
fi
+ fi
if [ "$IP" != "" ]; then
SHARE=`echo $SHARE | sed s/$HOST/$IP/`
fi
mountcmd="mount -t cifs -o user=$USER,password=$PASSWORD,$MOUNTOPTS $SHARE /data/library/music/$MOUNTID"
+ echo ${mountcmd}
${mountcmd}
if [ -x /opt/hifiberry/bin/report-activation ]; then
