Linux: Fix error: suggest explicit braces to avoid ambiguous ‘else’ [-Werror=dangling-else] with gcc 7.1

This commit is contained in:
Sergey Linev
2017-08-11 16:56:52 +00:00
committed by Marshall Greenblatt
parent 76eb49196e
commit 5b12134a45
8 changed files with 29 additions and 17 deletions

View File

@@ -344,8 +344,9 @@ void TestHandler::DestroyTest() {
void TestHandler::OnTestTimeout(int timeout_ms, bool treat_as_error) {
EXPECT_UI_THREAD();
if (treat_as_error)
if (treat_as_error) {
EXPECT_TRUE(false) << "Test timed out after " << timeout_ms << "ms";
}
DestroyTest();
}