2
0
mirror of https://github.com/boostorg/process.git synced 2026-01-19 04:22:15 +00:00

Fix: corrected empty double quotes being added to cmd.exe /c on Windows with bp::shell and bp::args (caused by PR #256)

This commit is contained in:
Konvicka Filip
2025-08-22 12:11:47 +02:00
committed by Klemens Morgenstern
parent 773ac747d5
commit 635c226066

View File

@@ -162,7 +162,9 @@ struct exe_cmd_init : handler_base_ext
}
static exe_cmd_init<Char> exe_args_shell(string_type && exe, std::vector<string_type> && args)
{
std::vector<string_type> args_ = {c_arg(Char()), std::move(exe)};
std::vector<string_type> args_ = {c_arg(Char())};
if (!exe.empty())
args_.emplace_back(std::move(exe));
args_.insert(args_.end(), std::make_move_iterator(args.begin()), std::make_move_iterator(args.end()));
string_type sh = get_shell(Char());