summaryrefslogtreecommitdiff
path: root/py/modules/IcePy/Communicator.cpp
diff options
context:
space:
mode:
authorMichi Henning <michi@zeroc.com>2007-06-22 16:36:14 +1000
committerMichi Henning <michi@zeroc.com>2007-06-22 16:36:14 +1000
commit33c7f4c5a8ff50f5c67757eda12e4092c98c818e (patch)
treef7013c9a1a81177c798d5da436fefd64dd3def4d /py/modules/IcePy/Communicator.cpp
parentbug 2157 - deprecating LocalObject mapping (diff)
downloadice-33c7f4c5a8ff50f5c67757eda12e4092c98c818e.tar.bz2
ice-33c7f4c5a8ff50f5c67757eda12e4092c98c818e.tar.xz
ice-33c7f4c5a8ff50f5c67757eda12e4092c98c818e.zip
Bug 2265.
Diffstat (limited to 'py/modules/IcePy/Communicator.cpp')
-rw-r--r--py/modules/IcePy/Communicator.cpp13
1 files changed, 10 insertions, 3 deletions
diff --git a/py/modules/IcePy/Communicator.cpp b/py/modules/IcePy/Communicator.cpp
index c21c05750cc..e6e5fe50c55 100644
--- a/py/modules/IcePy/Communicator.cpp
+++ b/py/modules/IcePy/Communicator.cpp
@@ -408,9 +408,10 @@ static PyObject*
communicatorIsShutdown(CommunicatorObject* self)
{
assert(self->communicator);
+ bool isShutdown;
try
{
- (*self->communicator)->isShutdown();
+ isShutdown = (*self->communicator)->isShutdown();
}
catch(const Ice::Exception& ex)
{
@@ -418,8 +419,14 @@ communicatorIsShutdown(CommunicatorObject* self)
return 0;
}
- Py_INCREF(Py_None);
- return Py_None;
+ if(isShutdown)
+ {
+ PyRETURN_TRUE;
+ }
+ else
+ {
+ PyRETURN_FALSE;
+ }
}
#ifdef WIN32