// file : libbutl/openssl.txx -*- C++ -*- // copyright : Copyright (c) 2014-2019 Code Synthesis Ltd // license : MIT; see accompanying LICENSE file LIBBUTL_MODEXPORT namespace butl //@@ MOD Clang needs this for some reason. { template typename std::enable_if::value, I>::type openssl:: map_in (I&& in, io_data&) { return std::forward (in); } template typename std::enable_if::value, O>::type openssl:: map_out (O&& out, io_data&) { return std::forward (out); } template openssl:: openssl (const C& cmdc, I&& in, O&& out, E&& err, const process_env& env, const std::string& command, A&&... options) { io_data in_data; io_data out_data; process& p (*this); p = process_start_callback (cmdc, map_in (std::forward (in), in_data), map_out (std::forward (out), out_data), std::forward (err), env, command, in_data.options, out_data.options, std::forward (options)...); // Note: leaving this scope closes any open ends of the pipes in io_data. } }