| 2151 | { |
| 2152 | template<typename F, typename... Args> |
| 2153 | OutBuffer check_output_impl(F& farg, Args&&... args) |
| 2154 | { |
| 2155 | static_assert(!detail::has_type<output, detail::param_pack<Args...>>::value, "output not allowed in args"); |
| 2156 | auto p = Popen(std::forward<F>(farg), std::forward<Args>(args)..., output{PIPE}); |
| 2157 | auto res = p.communicate(); |
| 2158 | auto retcode = p.retcode(); |
| 2159 | if (retcode > 0) { |
| 2160 | throw CalledProcessError("Command failed : Non zero retcode", retcode); |
| 2161 | } |
| 2162 | return std::move(res.first); |
| 2163 | } |
| 2164 | |
| 2165 | template<typename F, typename... Args> |
| 2166 | int call_impl(F& farg, Args&&... args) |
no test coverage detected