mirror of
https://github.com/Kitware/CMake.git
synced 2026-04-23 06:47:08 -05:00
Merge topic 'cpplint-no-output-no-warning'
c834c47dfc cpplint: only print diagnostics to console if there are errors
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2788
This commit is contained in:
+6
-3
@@ -270,9 +270,12 @@ static int HandleCppLint(const std::string& runCmd,
|
||||
<< "\n";
|
||||
return 1;
|
||||
}
|
||||
std::cerr << "Warning: cpplint diagnostics:\n";
|
||||
// Output the output from cpplint to stderr
|
||||
std::cerr << stdOut;
|
||||
if (!stdOut.empty()) {
|
||||
std::cerr << "Warning: cpplint diagnostics:\n";
|
||||
// Output the output from cpplint to stderr
|
||||
std::cerr << stdOut;
|
||||
}
|
||||
|
||||
// always return 0 so the build can continue as cpplint returns non-zero
|
||||
// for any warning
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user