MCPcopy Create free account
hub / github.com/InteractiveComputerGraphics/TriangleMeshDistance / OutputRedirect

Method OutputRedirect

tests/catch.hpp:9632–9639  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

9630 }
9631
9632 OutputRedirect::OutputRedirect(std::string& stdout_dest, std::string& stderr_dest) :
9633 m_originalStdout(dup(1)),
9634 m_originalStderr(dup(2)),
9635 m_stdoutDest(stdout_dest),
9636 m_stderrDest(stderr_dest) {
9637 dup2(fileno(m_stdoutFile.getFile()), 1);
9638 dup2(fileno(m_stderrFile.getFile()), 2);
9639 }
9640
9641 OutputRedirect::~OutputRedirect() {
9642 Catch::cout() << std::flush;

Callers

nothing calls this directly

Calls 1

getFileMethod · 0.80

Tested by

no test coverage detected