summaryrefslogtreecommitdiff
path: root/Source/cmCTest.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmCTest.cxx')
-rw-r--r--Source/cmCTest.cxx8
1 files changed, 5 insertions, 3 deletions
diff --git a/Source/cmCTest.cxx b/Source/cmCTest.cxx
index 225c99f7da..65c0d910a1 100644
--- a/Source/cmCTest.cxx
+++ b/Source/cmCTest.cxx
@@ -2853,9 +2853,11 @@ static const char* cmCTestStringLogType[] = { "DEBUG",
nullptr };
#define cmCTestLogOutputFileLine(stream) \
- if (this->ShowLineNumbers) { \
- (stream) << std::endl << file << ":" << line << " "; \
- }
+ do { \
+ if (this->ShowLineNumbers) { \
+ (stream) << std::endl << file << ":" << line << " "; \
+ } \
+ } while (false)
void cmCTest::InitStreams()
{