aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRob Landley <rob@landley.net>2020-07-15 22:20:14 -0500
committerRob Landley <rob@landley.net>2020-07-15 22:20:14 -0500
commit3eead7d3ae4ca93c4eda0167e679bd8d5aa1b59b (patch)
tree2d2db3848ad9fda7dc2dd826fdbf86131270ff45
parente2c176dd30a7b70f1e2273f6b5423e5a91841961 (diff)
downloadtoybox-3eead7d3ae4ca93c4eda0167e679bd8d5aa1b59b.tar.gz
toysh: NOSPLIT shouldn't collate whitespace $IFS
-rw-r--r--toys/pending/sh.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/toys/pending/sh.c b/toys/pending/sh.c
index 0dcf821f..d7615356 100644
--- a/toys/pending/sh.c
+++ b/toys/pending/sh.c
@@ -1153,7 +1153,7 @@ barf:
do {
// find end of (split) word
- if (qq&1) ss = ifs+strlen(ifs);
+ if ((qq&1) || (flags&NO_SPLIT)) ss = ifs+strlen(ifs);
else for (ss = ifs; *ss; ss += kk) if (utf8chr(ss, TT.ifs, &kk)) break;
// when no prefix, not splitting, no suffix: use existing memory