diff --git a/etc/rc.d/rc.local b/etc/rc.d/rc.local index 7ea2a4632..58a712981 100755 --- a/etc/rc.d/rc.local +++ b/etc/rc.d/rc.local @@ -193,13 +193,13 @@ fi # add new line with call to emhttp (preserve any params to emhttp and CRLF line endings) GOTEST1='^[^#]*/usr/local/sbin/emhttp(.*)&(.*)$' if grep -q -E "$GOTEST1" $CONFIG/go; then - cp $CONFIG/go $CONFIG/go- + cp $CONFIG/go $CONFIG/go~ sed -i -E "s@$GOTEST1@/usr/local/sbin/emhttp\1\2@g" $CONFIG/go fi # delete lines added by ProxyEditor GOTEST2='# Added by ProxyEditor' if grep -q "$GOTEST2" $CONFIG/go; then - [[ ! -f $CONFIG/go- ]] && cp $CONFIG/go $CONFIG/go- + [[ ! -f $CONFIG/go~ ]] && cp $CONFIG/go $CONFIG/go~ sed -i "/$GOTEST2/d" $CONFIG/go fi