summaryrefslogtreecommitdiff
path: root/py/modules/IcePy/Communicator.cpp
diff options
context:
space:
mode:
authorMark Spruiell <mes@zeroc.com>2006-06-20 19:21:45 +0000
committerMark Spruiell <mes@zeroc.com>2006-06-20 19:21:45 +0000
commit9976b425ffcbbb2ef4c3c760b54b6ad46cfde812 (patch)
tree0fbdc401689d8bad7bb8b50f4a57d58593d8f73f /py/modules/IcePy/Communicator.cpp
parentGramatical fix (diff)
downloadice-9976b425ffcbbb2ef4c3c760b54b6ad46cfde812.tar.bz2
ice-9976b425ffcbbb2ef4c3c760b54b6ad46cfde812.tar.xz
ice-9976b425ffcbbb2ef4c3c760b54b6ad46cfde812.zip
fixing bug 1109: hang in location test
Diffstat (limited to 'py/modules/IcePy/Communicator.cpp')
-rw-r--r--py/modules/IcePy/Communicator.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/py/modules/IcePy/Communicator.cpp b/py/modules/IcePy/Communicator.cpp
index f26465698ce..3f446674cb1 100644
--- a/py/modules/IcePy/Communicator.cpp
+++ b/py/modules/IcePy/Communicator.cpp
@@ -276,6 +276,7 @@ communicatorShutdown(CommunicatorObject* self)
assert(self->communicator);
try
{
+ AllowThreads allowThreads; // Release Python's global interpreter lock to avoid a potential deadlock.
(*self->communicator)->shutdown();
}
catch(const Ice::Exception& ex)
@@ -500,6 +501,7 @@ communicatorFlushBatchRequests(CommunicatorObject* self)
assert(self->communicator);
try
{
+ AllowThreads allowThreads; // Release Python's global interpreter lock to avoid a potential deadlock.
(*self->communicator)->flushBatchRequests();
}
catch(const Ice::Exception& ex)
@@ -714,7 +716,6 @@ communicatorGetDefaultContext(CommunicatorObject* self)
{
setPythonException(ex);
return NULL;
-
}
PyObjectHandle dict = PyDict_New();
@@ -836,6 +837,8 @@ communicatorCreateObjectAdapterWithRouter(CommunicatorObject* self, PyObject* ar
return NULL;
}
+ AllowThreads allowThreads; // Release Python's global interpreter lock to avoid a potential deadlock.
+
assert(self->communicator);
Ice::ObjectAdapterPtr adapter;
try