From c72b234cae060f03fc723accc4c6361925faa6e5 Mon Sep 17 00:00:00 2001 From: TheMarpe Date: Wed, 8 Feb 2023 13:07:25 +0200 Subject: [PATCH] Added a 'call' convenience overload --- subprocess.hpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/subprocess.hpp b/subprocess.hpp index aaed3c7..971a50e 100755 --- a/subprocess.hpp +++ b/subprocess.hpp @@ -786,7 +786,7 @@ struct input } explicit input(IOTYPE typ) { assert (typ == PIPE && "STDOUT/STDERR not allowed"); -#ifndef __USING_WINDOWS__ +#ifndef __USING_WINDOWS__ std::tie(rd_ch_, wr_ch_) = util::pipe_cloexec(); #endif } @@ -2050,6 +2050,11 @@ int call(const std::string& arg, Args&&... args) return (detail::call_impl(arg, std::forward(args)...)); } +template +int call(std::vector plist, Args &&... args) +{ + return (detail::call_impl(plist, std::forward(args)...)); +} /*! * Run the command with arguments and wait for it to complete.