From 9fc5e6217af3cf1267f88f76b48221a0675a53aa Mon Sep 17 00:00:00 2001 From: Gunnar Beutner Date: Mon, 14 Apr 2014 09:50:54 +0200 Subject: [PATCH] Build fix for Windows. Refs #6008 --- lib/base/exception.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/lib/base/exception.cpp b/lib/base/exception.cpp index 7f0f60ba6..b255440da 100644 --- a/lib/base/exception.cpp +++ b/lib/base/exception.cpp @@ -24,8 +24,7 @@ using namespace icinga; static boost::thread_specific_ptr l_LastExceptionStack; static boost::thread_specific_ptr l_LastExceptionContext; -#ifndef _WIN32 -#ifndef __GLIBCXX__ +#if !defined(__GLIBCXX__) && !defined(_WIN32) static boost::thread_specific_ptr l_LastExceptionObj; static boost::thread_specific_ptr l_LastExceptionPvtInfo; @@ -34,17 +33,18 @@ static boost::thread_specific_ptr l_LastExceptionDest; extern "C" void __cxa_throw(void *obj, void *pvtinfo, void (*dest)(void *)); extern "C" void __cxa_rethrow_primary_exception(void* thrown_object); -#endif /* __GLIBCXX__ */ +#endif /* !__GLIBCXX__ && !_WIN32 */ void icinga::RethrowUncaughtException(void) { -#ifdef __GLIBCXX__ +#if defined(__GLIBCXX__) || defined(_WIN32) throw; -#else /* __GLIBCXX__ */ +#else /* __GLIBCXX__ || _WIN32 */ __cxa_throw(*l_LastExceptionObj.get(), *l_LastExceptionPvtInfo.get(), *l_LastExceptionDest.get()); -#endif /* __GLIBCXX__ */ +#endif /* __GLIBCXX__ || _WIN32 */ } +#ifndef _WIN32 extern "C" void __cxa_throw(void *obj, void *pvtinfo, void (*dest)(void *)) { -- 2.50.1