diff --git a/src/builtins/path.cpp b/src/builtins/path.cpp index c0ffe8301..41a2c53b4 100644 --- a/src/builtins/path.cpp +++ b/src/builtins/path.cpp @@ -691,7 +691,9 @@ static int path_resolve(parser_t &parser, io_streams_t &streams, int argc, const real = normalize_path(*real, false); break; } - rest = wbasename(next) + L'/' + rest; + rest = wbasename(next); + rest += L'/'; + rest += rest; } if (!real) { continue;