ash: unbreak PS1 parsing after "ash: parser: Add syntax stack..." commit
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
parent
fbf44854a3
commit
ee1fd1246e
@ -11959,7 +11959,7 @@ readtoken1(int c, int syntax, char *eofmark, int striptabs)
|
|||||||
smallint pssyntax; /* we are expanding a prompt string */
|
smallint pssyntax; /* we are expanding a prompt string */
|
||||||
IF_BASH_DOLLAR_SQUOTE(smallint bash_dollar_squote = 0;)
|
IF_BASH_DOLLAR_SQUOTE(smallint bash_dollar_squote = 0;)
|
||||||
/* syntax stack */
|
/* syntax stack */
|
||||||
struct synstack synbase = { .syntax = syntax };
|
struct synstack synbase = { };
|
||||||
struct synstack *synstack = &synbase;
|
struct synstack *synstack = &synbase;
|
||||||
|
|
||||||
#if ENABLE_ASH_EXPAND_PRMT
|
#if ENABLE_ASH_EXPAND_PRMT
|
||||||
@ -11969,6 +11969,8 @@ readtoken1(int c, int syntax, char *eofmark, int striptabs)
|
|||||||
#else
|
#else
|
||||||
pssyntax = 0; /* constant */
|
pssyntax = 0; /* constant */
|
||||||
#endif
|
#endif
|
||||||
|
synstack->syntax = syntax;
|
||||||
|
|
||||||
if (syntax == DQSYNTAX)
|
if (syntax == DQSYNTAX)
|
||||||
synstack->dblquote = 1;
|
synstack->dblquote = 1;
|
||||||
quotef = 0;
|
quotef = 0;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user