recovery-utils: relax command mode check
As a result of the dualboot support we may end up with two 'update-firmware' commands in the rootfs. To prevent file name clashing, we may need to install the recovery-utils update-firmware as update-firmware.recovery, and then the current command mode check would fail. Relax the check, by just looking at the first character. Signed-off-by: Javier Viguera <javier.viguera@digi.com>
This commit is contained in:
parent
9812149ca5
commit
bbd58825c4
|
|
@ -87,8 +87,8 @@
|
||||||
"\n"
|
"\n"
|
||||||
|
|
||||||
/* Check if application was called as update-firmware or encrypt-partitions */
|
/* Check if application was called as update-firmware or encrypt-partitions */
|
||||||
#define IS_UPDATEFW(cmd) (!strcmp(cmd, CMD_UPDATEFW))
|
#define IS_UPDATEFW(cmd) (cmd[0] == 'u')
|
||||||
#define IS_ENCRYPT(cmd) (!strcmp(cmd, CMD_ENCRYPT))
|
#define IS_ENCRYPT(cmd) (cmd[0] == 'e')
|
||||||
|
|
||||||
/* Actual command name */
|
/* Actual command name */
|
||||||
static char *cmd_name;
|
static char *cmd_name;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue