MCPcopy Create free account
hub / github.com/Predelnik/DSpellCheck / OutputRedirect

Method OutputRedirect

deps/Catch/catch.hpp:12090–12097  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

12088 }
12089
12090 OutputRedirect::OutputRedirect(std::string& stdout_dest, std::string& stderr_dest) :
12091 m_originalStdout(dup(1)),
12092 m_originalStderr(dup(2)),
12093 m_stdoutDest(stdout_dest),
12094 m_stderrDest(stderr_dest) {
12095 dup2(fileno(m_stdoutFile.getFile()), 1);
12096 dup2(fileno(m_stderrFile.getFile()), 2);
12097 }
12098
12099 OutputRedirect::~OutputRedirect() {
12100 Catch::cout() << std::flush;

Callers

nothing calls this directly

Calls 1

getFileMethod · 0.80

Tested by

no test coverage detected