From ba8ae43a266a96126c3959e0b9a9f05e40e38e69 Mon Sep 17 00:00:00 2001 From: jzmaddock Date: Sun, 6 Sep 2015 09:51:44 +0100 Subject: [PATCH] Allow timer to be built with -fno-exceptions --- src/cpu_timer.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/cpu_timer.cpp b/src/cpu_timer.cpp index efe4afc..e71b3a5 100644 --- a/src/cpu_timer.cpp +++ b/src/cpu_timer.cpp @@ -247,13 +247,17 @@ namespace boost if (!is_stopped()) { stop(); // the sooner we stop(), the better +#ifndef BOOST_NO_EXCEPTIONS try { +#endif report(); +#ifndef BOOST_NO_EXCEPTIONS } catch (...) // eat any exceptions { } +#endif } }