← Commit list

ad4e96135

Martijn Dekker
Martijn Dekker
2018-03-31
SUCCESS Duration: 145s

Subject

ash: 'nolog' and 'debug' options cause "$-" to wreak havoc

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 -1
@@ -7192,7 +7192,7 @@ varvalue(char *name, int varflags, int flags, int *quotedp)
case '-':
expdest = makestrspace(NOPTS, expdest);
for (i = NOPTS - 1; i >= 0; i--) {
- if (optlist[i]) {
+ if (optlist[i] && optletters(i)) {
USTPUTC(optletters(i), expdest);
len++;
}