File tree Expand file tree Collapse file tree 1 file changed +9
-9
lines changed
Expand file tree Collapse file tree 1 file changed +9
-9
lines changed Original file line number Diff line number Diff line change 9090namespace testing {
9191namespace internal {
9292
93- #if defined(_MSC_VER) || defined(__BORLANDC__)
94- // MSVC and C++Builder do not provide a definition of STDERR_FILENO.
95- const int kStdOutFileno = 1 ;
96- const int kStdErrFileno = 2 ;
97- #else
98- const int kStdOutFileno = STDOUT_FILENO;
99- const int kStdErrFileno = STDERR_FILENO;
100- #endif // _MSC_VER
101-
10293#if GTEST_OS_LINUX || GTEST_OS_GNU_HURD
10394
10495namespace {
@@ -1177,6 +1168,15 @@ static std::string GetCapturedStream(CapturedStream** captured_stream) {
11771168 return content;
11781169}
11791170
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 // defined(_MSC_VER) || defined(__BORLANDC__)
1179+
11801180// Starts capturing stdout.
11811181void CaptureStdout () {
11821182 CaptureStream (kStdOutFileno , " stdout" , &g_captured_stdout);
You can’t perform that action at this time.
0 commit comments