MCPcopy Create free account
hub / github.com/OpenPTrack/open_ptrack_v2 / CaptureStream

Function CaptureStream

rtpose_wrapper/src/gtest/gtest-all.cpp:8393–8399  ·  view source on GitHub ↗

Starts capturing an output stream (stdout/stderr).

Source from the content-addressed store, hash-verified

8391
8392// Starts capturing an output stream (stdout/stderr).
8393void CaptureStream(int fd, const char* stream_name, CapturedStream** stream) {
8394 if (*stream != NULL) {
8395 GTEST_LOG_(FATAL) << "Only one " << stream_name
8396 << " capturer can exist at a time.";
8397 }
8398 *stream = new CapturedStream(fd);
8399}
8400
8401// Stops capturing the output stream and returns the captured string.
8402String GetCapturedStream(CapturedStream** captured_stream) {

Callers 2

CaptureStdoutFunction · 0.85
CaptureStderrFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected