From 43d36f35471ddacad4fc23196a557fa2e6e38c88 Mon Sep 17 00:00:00 2001 From: Sangyoon Jang Date: Mon, 3 Aug 2020 16:32:26 +0900 Subject: [PATCH] Fix static analysis issue Fix uncaught exepction. Change-Id: Iaecd4303cbdc18e848b614e3df8520ee05a85b9b Signed-off-by: Sangyoon Jang (cherry picked from commit 7335f169e18a7b152b4390a4da19400a726c897e) --- src/unit_tests/recovery_test.cc | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/unit_tests/recovery_test.cc b/src/unit_tests/recovery_test.cc index 2cbcefc..183f126 100644 --- a/src/unit_tests/recovery_test.cc +++ b/src/unit_tests/recovery_test.cc @@ -397,6 +397,11 @@ int main(int argc, char** argv) { } } bpo::notify(opt_map); + + if (req_type == ReqType::UNKNOWN_REQ) { + std::cerr << options << std::endl; + return 0; + } } catch (...) { std::cerr << "Exception occurred: " << boost::current_exception_diagnostic_information() @@ -404,11 +409,6 @@ int main(int argc, char** argv) { return -1; } - if (req_type == ReqType::UNKNOWN_REQ) { - std::cerr << options << std::endl; - return 0; - } - try { char buf[10][kBufSize] = { 0, }; std::vector gtest_argv; -- 2.34.1