summaryrefslogtreecommitdiff
path: root/cpp
diff options
context:
space:
mode:
authorJose <jose@zeroc.com>2014-03-26 19:44:41 +0100
committerJose <jose@zeroc.com>2014-03-26 19:44:41 +0100
commitc33492b10e81720a638c8c7e423a5c4ef4ba7dc4 (patch)
treee9ff84c44a44584186766fd6fa65680e4fbefd07 /cpp
parentFixed (ICE-5502) - -D__SLICE2CS__ in slice2js/Main.cpp (diff)
downloadice-c33492b10e81720a638c8c7e423a5c4ef4ba7dc4.tar.bz2
ice-c33492b10e81720a638c8c7e423a5c4ef4ba7dc4.tar.xz
ice-c33492b10e81720a638c8c7e423a5c4ef4ba7dc4.zip
Fixed (ICE-5505) - Outgoing ice_stackTrace only for __GNUC__
Diffstat (limited to 'cpp')
-rw-r--r--cpp/src/Ice/Outgoing.cpp14
1 files changed, 11 insertions, 3 deletions
diff --git a/cpp/src/Ice/Outgoing.cpp b/cpp/src/Ice/Outgoing.cpp
index 075ae740caa..5601a705641 100644
--- a/cpp/src/Ice/Outgoing.cpp
+++ b/cpp/src/Ice/Outgoing.cpp
@@ -24,6 +24,13 @@ using namespace Ice;
using namespace Ice::Instrumentation;
using namespace IceInternal;
+namespace IceUtilInternal
+{
+
+extern bool ICE_DECLSPEC_IMPORT printStackTraces;
+
+}
+
IceInternal::LocalExceptionWrapper::LocalExceptionWrapper(const LocalException& ex, bool r) :
_retry(r)
{
@@ -60,9 +67,10 @@ IceInternal::LocalExceptionWrapper::throwWrapper(const std::exception& ex)
}
stringstream s;
s << *le;
-#ifdef __GNUC__
- s << "\n" << le->ice_stackTrace();
-#endif
+ if(IceUtilInternal::printStackTraces)
+ {
+ s << "\n" << le->ice_stackTrace();
+ }
throw LocalExceptionWrapper(UnknownLocalException(__FILE__, __LINE__, s.str()), false);
}
string msg = "std::exception: ";