From 83c06a47297cfe1e97240e52e98b403dfcfc858e Mon Sep 17 00:00:00 2001 From: Carles Fernandez Date: Sat, 26 May 2018 09:33:57 +0200 Subject: [PATCH] Catch all exceptions --- src/utils/front-end-cal/main.cc | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/src/utils/front-end-cal/main.cc b/src/utils/front-end-cal/main.cc index 7a90e0cc8..0b1429b8c 100644 --- a/src/utils/front-end-cal/main.cc +++ b/src/utils/front-end-cal/main.cc @@ -308,11 +308,18 @@ int main(int argc, char** argv) // 2. Get SUPL information from server: Ephemeris record, assistance info and TOW - if (front_end_cal.get_ephemeris() == true) + try { - std::cout << "SUPL data received OK!" << std::endl; + if (front_end_cal.get_ephemeris() == true) + { + std::cout << "SUPL data received OK!" << std::endl; + } + else + { + std::cout << "Failure connecting to SUPL server" << std::endl; + } } - else + catch (const boost::exception& e) { std::cout << "Failure connecting to SUPL server" << std::endl; }