aboutsummaryrefslogtreecommitdiff
path: root/shell/ash.c
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2016-09-29 17:58:58 +0200
committerDenys Vlasenko <vda.linux@googlemail.com>2016-09-29 17:58:58 +0200
commit459293b1c536515fbe7fafbae9932aefadb2fbaf (patch)
tree949cfa9001df3b0bea827200565eb8f36f028939 /shell/ash.c
parent73c3e074df4de03ba1bebce09c130c8950ea5fe4 (diff)
downloadbusybox-w32-459293b1c536515fbe7fafbae9932aefadb2fbaf.tar.gz
busybox-w32-459293b1c536515fbe7fafbae9932aefadb2fbaf.tar.bz2
busybox-w32-459293b1c536515fbe7fafbae9932aefadb2fbaf.zip
ash: fix arithmetic closing )) split by backslash-newline
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'shell/ash.c')
-rw-r--r--shell/ash.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/shell/ash.c b/shell/ash.c
index b71fc0299..97f8d9377 100644
--- a/shell/ash.c
+++ b/shell/ash.c
@@ -11437,7 +11437,7 @@ readtoken1(int c, int syntax, char *eofmark, int striptabs)
11437 if (parenlevel > 0) { 11437 if (parenlevel > 0) {
11438 parenlevel--; 11438 parenlevel--;
11439 } else { 11439 } else {
11440 if (pgetc() == ')') { 11440 if (pgetc_eatbnl() == ')') {
11441 c = CTLENDARI; 11441 c = CTLENDARI;
11442 if (--arinest == 0) { 11442 if (--arinest == 0) {
11443 syntax = prevsyntax; 11443 syntax = prevsyntax;
@@ -11464,6 +11464,7 @@ readtoken1(int c, int syntax, char *eofmark, int striptabs)
11464 if (varnest == 0) { 11464 if (varnest == 0) {
11465#if ENABLE_ASH_BASH_COMPAT 11465#if ENABLE_ASH_BASH_COMPAT
11466 if (c == '&') { 11466 if (c == '&') {
11467//Can't call pgetc_eatbnl() here, this requires three-deep pungetc()
11467 if (pgetc() == '>') 11468 if (pgetc() == '>')
11468 c = 0x100 + '>'; /* flag &> */ 11469 c = 0x100 + '>'; /* flag &> */
11469 pungetc(); 11470 pungetc();