← Commit list

0e056f7e9

Ron Yorston
Ron Yorston
2015-07-13
SUCCESS Duration: 193s

Subject

ash: remove parsebackquote flag

Binary

No binary (build failed)

Architecture & Compiler Flags

Architecture: x86_64-linux-gnu Compiler: gcc (Ubuntu 11.4.0-1ubuntu1~22.04.3) 11.4.0

—

Build Log

(log yok)

Commit Diff GitHub →

shell/ash.c+1 -7
@@ -10473,7 +10473,6 @@ struct heredoc {
};
static smallint tokpushback; /* last token pushed back */
-static smallint parsebackquote; /* nonzero if we are inside backquotes */
static smallint quoteflag; /* set if (part of) last token was quoted */
static token_id_t lasttoken; /* last token read (integer id Txxx) */
static struct heredoc *heredoclist; /* list of here documents to read */
@@ -11313,7 +11312,7 @@ readtoken1(int c, int syntax, char *eofmark, int striptabs)
if (syntax == ARISYNTAX)
raise_error_syntax("missing '))'");
#endif
- if (syntax != BASESYNTAX && !parsebackquote && eofmark == NULL)
+ if (syntax != BASESYNTAX && eofmark == NULL)
raise_error_syntax("unterminated quoted string");
if (varnest != 0) {
startlinno = g_parsefile->linno;
@@ -11609,7 +11608,6 @@ parsesub: {
*/
parsebackq: {
struct nodelist **nlpp;
- smallint savepbq;
union node *n;
char *volatile str;
struct jmploc jmploc;
@@ -11620,10 +11618,8 @@ parsebackq: {
#ifdef __GNUC__
(void) &saveprompt;
#endif
- savepbq = parsebackquote;
if (setjmp(jmploc.loc)) {
free(str);
- parsebackquote = 0;
exception_handler = savehandler;
longjmp(exception_handler->loc, 1);
}
@@ -11707,7 +11703,6 @@ parsebackq: {
nlpp = &(*nlpp)->next;
*nlpp = stzalloc(sizeof(**nlpp));
/* (*nlpp)->next = NULL; - stzalloc did it */
- parsebackquote = oldstyle;
if (oldstyle) {
saveprompt = doprompt;
@@ -11741,7 +11736,6 @@ parsebackq: {
str = NULL;
INT_ON;
}
- parsebackquote = savepbq;
exception_handler = savehandler;
USTPUTC(CTLBACKQ, out);
if (oldstyle)
shell/ash_test/ash-misc/tickquote1.right+1 -0
@@ -0,0 +1 @@
+./tickquote1.tests: line 1: syntax error: unterminated quoted string
shell/ash_test/ash-misc/tickquote1.tests+1 -0
@@ -0,0 +1 @@
+echo `"pwd`