diff --git a/files/lib/gluon/ssid-changer/ssid-changer.sh b/files/lib/gluon/ssid-changer/ssid-changer.sh index ab74733f4f8d0308ce18311fdf2a34c04c7e0b8b..281a15896f38d04bfef1338d7fb417cebbb314b4 100755 --- a/files/lib/gluon/ssid-changer/ssid-changer.sh +++ b/files/lib/gluon/ssid-changer/ssid-changer.sh @@ -7,12 +7,12 @@ OFFLINE_PREFIX='FF_OFFLINE_' # Use something short to leave space for the nodena # Generate an Offline SSID with the first and last Part of the nodename to allow owner to recognise wich node is down NODENAME=`uname -n` -if [ ${#NODENAME} > 30-${#OFFLINE_PREFIX} ] ; then #32 would be possible as well +if [ ${#NODENAME} > $(30-${#OFFLINE_PREFIX}) ] ; then #32 would be possible as well HALF=$(( (28 - ${#OFFLINE_PREFIX} ) / 2 )) SKIP=$(( ${#NODENAME} - $HALF )) OFFLINE_SSID=$OFFLINE_PREFIX${NODENAME:0:$HALF}...${NODENAME:$SKIP:${#NODENAME}} # use the first and last part of the nodename for nodes with long name else - OFFLINE_SSID=`$OFFLINE_PREFIX$NODENAME` + OFFLINE_SSID="$OFFLINE_PREFIX$NODENAME" fi #Is there an active Gateway?