[BUG] 'case' does not match double-quoted backslash

Martijn Dekker martijn at inlv.org
Tue Feb 13 10:42:08 UTC 2018


Op 13-02-18 om 08:12 schreef dietmar.schindler at manroland-web.com:
> Von: Kang-Che Sung
> Gesendet: Dienstag, 13. Februar 2018 04:52
>> It says the backslash is special only when followed by the $ ` " \
>> <newline> characters.
>> That is, \$ \` \" \\ and \<newline> are special, but none of these
>> includes the \z you
>> mentioned, so what you described is an undefined behavior.
> 
> "The <backslash> shall retain its special meaning ... only when
> followed ..." means that in other cases it has no special meaning.
> Having no special meaning does not mean undefined behavior, but
> rather normal behavior (as an ordinary character).

Precisely. If the standard meant that to be undefined behaviour, it
would explicitly say so (as it does in many cases of actual undefined
behaviour). Also, compare the behaviour of *any* other shell. There is a
clear consensus there.

But, even if the behaviour were undefined, it should not silently change
from one busybox version to the next. It breaks backwards compatibility.

- M.


More information about the busybox mailing list