summaryrefslogtreecommitdiff
path: root/cpp/src/IceUtil/Exception.cpp
diff options
context:
space:
mode:
authorBenoit Foucher <benoit@zeroc.com>2009-09-09 20:47:14 +0200
committerBenoit Foucher <benoit@zeroc.com>2009-09-09 20:47:14 +0200
commit42046f618d3ca66f8fa1ff8f27f862416d3d0ac8 (patch)
tree48f1ef05110d097025e4c68f786713c3cd75a1a3 /cpp/src/IceUtil/Exception.cpp
parent- cpp/demo/Ice/session now uses a timer for the periodic reaping. (diff)
downloadice-42046f618d3ca66f8fa1ff8f27f862416d3d0ac8.tar.bz2
ice-42046f618d3ca66f8fa1ff8f27f862416d3d0ac8.tar.xz
ice-42046f618d3ca66f8fa1ff8f27f862416d3d0ac8.zip
Fixed Visual Studio compilation error related to printStackTraces and minor cleanup
Diffstat (limited to 'cpp/src/IceUtil/Exception.cpp')
-rw-r--r--cpp/src/IceUtil/Exception.cpp21
1 files changed, 5 insertions, 16 deletions
diff --git a/cpp/src/IceUtil/Exception.cpp b/cpp/src/IceUtil/Exception.cpp
index a2f973fc979..f3e2cc9b750 100644
--- a/cpp/src/IceUtil/Exception.cpp
+++ b/cpp/src/IceUtil/Exception.cpp
@@ -24,7 +24,8 @@ using namespace std;
namespace IceUtilInternal
{
-bool printStackTraces = false;
+bool ICE_DECLSPEC_EXPORT printStackTraces = false;
+bool ICE_DECLSPEC_EXPORT nullHandleAbort = false;
}
@@ -51,19 +52,7 @@ public:
Init init;
-}
-
-namespace IceUtil
-{
-
-bool ICE_DECLSPEC_EXPORT nullHandleAbort = false;
-
-};
-
#ifdef __GNUC__
-namespace
-{
-
string
getStackTrace()
{
@@ -187,10 +176,10 @@ getStackTrace()
return stackTrace;
}
-
-};
#endif
+}
+
IceUtil::Exception::Exception() :
_file(0),
_line(0)
@@ -293,7 +282,7 @@ IceUtil::operator<<(ostream& out, const IceUtil::Exception& ex)
IceUtil::NullHandleException::NullHandleException(const char* file, int line) :
Exception(file, line)
{
- if(nullHandleAbort)
+ if(IceUtilInternal::nullHandleAbort)
{
abort();
}