File tree Expand file tree Collapse file tree 1 file changed +9
-11
lines changed
Expand file tree Collapse file tree 1 file changed +9
-11
lines changed Original file line number Diff line number Diff line change 9090namespace testing {
9191namespace internal {
9292
93- #if GTEST_HAS_STREAM_REDIRECTION
94- #if defined(_MSC_VER) || defined(__BORLANDC__)
95- // MSVC and C++Builder do not provide a definition of STDERR_FILENO.
96- const int kStdOutFileno = 1 ;
97- const int kStdErrFileno = 2 ;
98- #else
99- const int kStdOutFileno = STDOUT_FILENO;
100- const int kStdErrFileno = STDERR_FILENO;
101- #endif // _MSC_VER
102- #endif // GTEST_HAS_STREAM_REDIRECTION
103-
10493#if GTEST_OS_LINUX || GTEST_OS_GNU_HURD
10594
10695namespace {
@@ -1179,6 +1168,15 @@ static std::string GetCapturedStream(CapturedStream** captured_stream) {
11791168 return content;
11801169}
11811170
1171+ #if defined(_MSC_VER) || defined(__BORLANDC__)
1172+ // MSVC and C++Builder do not provide a definition of STDERR_FILENO.
1173+ const int kStdOutFileno = 1 ;
1174+ const int kStdErrFileno = 2 ;
1175+ #else
1176+ const int kStdOutFileno = STDOUT_FILENO;
1177+ const int kStdErrFileno = STDERR_FILENO;
1178+ #endif // _MSC_VER
1179+
11821180// Starts capturing stdout.
11831181void CaptureStdout () {
11841182 CaptureStream (kStdOutFileno , " stdout" , &g_captured_stdout);
You can’t perform that action at this time.
0 commit comments