mirror of
https://github.com/fish-shell/fish-shell
synced 2024-12-26 04:43:10 +00:00
[string] Allow join to handle NULs
This commit is contained in:
parent
aedb8dc327
commit
bcd23ff971
1 changed files with 2 additions and 2 deletions
|
@ -656,12 +656,12 @@ static int string_join(parser_t &parser, io_streams_t &streams, int argc, wchar_
|
|||
const wchar_t *sep = opts.arg1;
|
||||
int nargs = 0;
|
||||
arg_iterator_t aiter(argv, optind, streams);
|
||||
while (const wchar_t *arg = aiter.next()) {
|
||||
while (auto arg = aiter.nextstr()) {
|
||||
if (!opts.quiet) {
|
||||
if (nargs > 0) {
|
||||
streams.out.append(sep);
|
||||
}
|
||||
streams.out.append(arg);
|
||||
streams.out.append(*arg);
|
||||
}
|
||||
nargs++;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue