summaryrefslogtreecommitdiff
path: root/cpp/src/IceDiscovery/PluginI.cpp
diff options
context:
space:
mode:
authorBenoit Foucher <benoit@zeroc.com>2015-02-06 11:05:54 +0100
committerBenoit Foucher <benoit@zeroc.com>2015-02-06 11:05:54 +0100
commit542bd45d571c9ca66ef273f6d20c9d86e11faf6c (patch)
tree8ac07a02d1b6b2849f0d78f6898c80286c5e5f3b /cpp/src/IceDiscovery/PluginI.cpp
parentUpdate ubuntu packages to sign icegridgui.jar and version fixes (diff)
downloadice-542bd45d571c9ca66ef273f6d20c9d86e11faf6c.tar.bz2
ice-542bd45d571c9ca66ef273f6d20c9d86e11faf6c.tar.xz
ice-542bd45d571c9ca66ef273f6d20c9d86e11faf6c.zip
Fixed Ice discovery plugins to not block on init
Diffstat (limited to 'cpp/src/IceDiscovery/PluginI.cpp')
-rw-r--r--cpp/src/IceDiscovery/PluginI.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/cpp/src/IceDiscovery/PluginI.cpp b/cpp/src/IceDiscovery/PluginI.cpp
index 32802631c43..fd4d6dbdf03 100644
--- a/cpp/src/IceDiscovery/PluginI.cpp
+++ b/cpp/src/IceDiscovery/PluginI.cpp
@@ -107,7 +107,12 @@ PluginI::initialize()
try
{
// Ensure we can establish a connection to the multicast proxy
- lookupPrx->ice_getConnection();
+ // but don't block.
+ Ice::AsyncResultPtr result = lookupPrx->begin_ice_getConnection();
+ if(result->sentSynchronously())
+ {
+ lookupPrx->end_ice_getConnection(result);
+ }
}
catch(const Ice::LocalException& ex)
{