From 6941c94c4a77d13bbcfb95d44941f4aaadca01c4 Mon Sep 17 00:00:00 2001 From: Fabian Homborg Date: Wed, 27 Oct 2021 10:20:14 +0200 Subject: [PATCH] cd: Set var via the string This was meant to trigger the wcstring_list_t overload by constructing one with `{norm_dir}`. Older gcc can't figure out what to do. So instead we use the wcstring overload for now. --- src/builtin_cd.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/builtin_cd.cpp b/src/builtin_cd.cpp index 5f9dceedf..23da07483 100644 --- a/src/builtin_cd.cpp +++ b/src/builtin_cd.cpp @@ -101,7 +101,7 @@ maybe_t builtin_cd(parser_t &parser, io_streams_t &streams, const wchar_t * } parser.libdata().cwd_fd = std::make_shared(std::move(dir_fd)); - parser.set_var_and_fire(L"PWD", ENV_EXPORT | ENV_GLOBAL, {norm_dir}); + parser.set_var_and_fire(L"PWD", ENV_EXPORT | ENV_GLOBAL, std::move(norm_dir)); return STATUS_CMD_OK; }