>> diff --git a/package/base-files/files/sbin/sysupgrade 
>> b/package/base-files/files/sbin/sysupgrade
>> index 56e9a92..033bd35 100755
>> --- a/package/base-files/files/sbin/sysupgrade
>> +++ b/package/base-files/files/sbin/sysupgrade
>> @@ -32,7 +32,7 @@ while [ -n "$1" ]; do
>>               -r|--restore-backup) export CONF_RESTORE="$2" NEED_IMAGE=1; 
>> shift;;
>>               -l|--list-backup) export CONF_BACKUP_LIST=1; break;;
>>               -f) export CONF_IMAGE="$2"; shift;;
>> -             -F|--force) export FORCE=1;;
>> +             -F|--force) export FORCE="$(($FORCE + 1))";;
>>               -T|--test) export TEST=1;;
>>               -h|--help) export HELP=1; break;;
>>               -*)
>
> I'm feeling a bit uneasy about changing that assignment
> into an increment of a variable
> that thereby loses its initialization (or is it already initialized 
> elsewhere?).
>

We already initialize FORCE to 0 at the top of the 'sysupgrade' script.

    export HELP=0
    export FORCE=0
    export TEST=0
_______________________________________________
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel

Reply via email to