mirror of
https://git.busybox.net/busybox.git
synced 2024-12-18 09:53:23 +08:00
tr: fix "tr [=" case. Closes bug 4374.
function old new delta expand 1701 1738 +37 tr_main 472 474 +2
This commit is contained in:
parent
918a34b9e0
commit
043d15da31
@ -135,6 +135,8 @@ static unsigned int expand(const char *arg, char *buffer)
|
||||
/* "[xyz...", i=x, arg points to y */
|
||||
if (ENABLE_FEATURE_TR_EQUIV && i == '=') { /* [=CHAR=] */
|
||||
*buffer++ = *arg; /* copy CHAR */
|
||||
if (!*arg || arg[1] != '=' || arg[2] != ']')
|
||||
bb_show_usage();
|
||||
arg += 3; /* skip CHAR=] */
|
||||
continue;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user