diff options
author | Ron Yorston <rmy@pobox.com> | 2014-01-12 08:48:46 +0000 |
---|---|---|
committer | Ron Yorston <rmy@pobox.com> | 2014-01-12 08:48:46 +0000 |
commit | e371e46fa07eb850d28bc5738e04e6575c32be2e (patch) | |
tree | 26754421577f07cc0fe63dffe7982b81d874a7cf /shell | |
parent | 3eff46194e1879b27017df5fb18862289c07f57c (diff) | |
download | busybox-w32-e371e46fa07eb850d28bc5738e04e6575c32be2e.tar.gz busybox-w32-e371e46fa07eb850d28bc5738e04e6575c32be2e.tar.bz2 busybox-w32-e371e46fa07eb850d28bc5738e04e6575c32be2e.zip |
shell: add \r to IFS
When commands run in backquotes generated multiple lines of
output the carriage returns weren't being removed. Adding \r
to IFS fixes this.
Diffstat (limited to 'shell')
-rw-r--r-- | shell/shell_common.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/shell/shell_common.c b/shell/shell_common.c index 782d47285..52e1025a2 100644 --- a/shell/shell_common.c +++ b/shell/shell_common.c | |||
@@ -20,7 +20,11 @@ | |||
20 | #include "shell_common.h" | 20 | #include "shell_common.h" |
21 | #include <sys/resource.h> /* getrlimit */ | 21 | #include <sys/resource.h> /* getrlimit */ |
22 | 22 | ||
23 | #if !ENABLE_PLATFORM_MINGW32 | ||
23 | const char defifsvar[] ALIGN1 = "IFS= \t\n"; | 24 | const char defifsvar[] ALIGN1 = "IFS= \t\n"; |
25 | #else | ||
26 | const char defifsvar[] ALIGN1 = "IFS= \t\n\r"; | ||
27 | #endif | ||
24 | 28 | ||
25 | 29 | ||
26 | int FAST_FUNC is_well_formed_var_name(const char *s, char terminator) | 30 | int FAST_FUNC is_well_formed_var_name(const char *s, char terminator) |