From d8d98e3380abb6ae20448bbc474bb143ffece897 Mon Sep 17 00:00:00 2001 From: Joseph Mirabel <jmirabel@laas.fr> Date: Fri, 5 Jan 2018 15:40:18 +0100 Subject: [PATCH] Remove unnecessary try/catch --- src/steering-method/cross-state-optimization.cc | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/src/steering-method/cross-state-optimization.cc b/src/steering-method/cross-state-optimization.cc index f6aaa4d7..7d5ccb9d 100644 --- a/src/steering-method/cross-state-optimization.cc +++ b/src/steering-method/cross-state-optimization.cc @@ -572,14 +572,10 @@ namespace hpp { } if (ok && optData.solve()) { - try { - core::PathPtr_t path = buildPath (optData, transitions); - if (path) return path; - } catch (const std::runtime_error& e) { - hppDout (warning, "Could not build path from solution " + core::PathPtr_t path = buildPath (optData, transitions); + if (path) return path; + hppDout (info, "Failed to build path from solution: " << pinocchio::displayConfig(optData.q)); - } - hppDout (info, "Failed to build"); } else { hppDout (info, "Failed to solve"); } -- GitLab