Do not add NULL at end of commandLine on Windows.

This commit is contained in:
Matthieu Gautier
2018-10-31 12:45:08 +01:00
parent 1787e30440
commit bb07ff5610
7 changed files with 10 additions and 10 deletions

View File

@@ -8,7 +8,7 @@
# include "subprocess_unix.h"
#endif
Subprocess::Subprocess(std::unique_ptr<SubprocessImpl> impl, const commandLine_t& commandLine) :
Subprocess::Subprocess(std::unique_ptr<SubprocessImpl> impl, commandLine_t& commandLine) :
mp_impl(std::move(impl))
{
mp_impl->run(commandLine);
@@ -19,7 +19,7 @@ Subprocess::~Subprocess()
mp_impl->kill();
}
std::unique_ptr<Subprocess> Subprocess::run(const commandLine_t& commandLine)
std::unique_ptr<Subprocess> Subprocess::run(commandLine_t& commandLine)
{
#ifdef _WIN32
auto impl = std::unique_ptr<SubprocessImpl>(new WinImpl);