diff options
Diffstat (limited to 'cpp/src/IcePatch2/ClientUtil.cpp')
-rwxr-xr-x | cpp/src/IcePatch2/ClientUtil.cpp | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/cpp/src/IcePatch2/ClientUtil.cpp b/cpp/src/IcePatch2/ClientUtil.cpp index 2c6f736f436..08460af418e 100755 --- a/cpp/src/IcePatch2/ClientUtil.cpp +++ b/cpp/src/IcePatch2/ClientUtil.cpp @@ -163,16 +163,11 @@ IcePatch2::Patcher::Patcher(const CommunicatorPtr& communicator, const PatcherFe throw string("property `") + endpointsProperty + "' is not set"; } - const char* idProperty = "IcePatch2.Identity"; - string idStr = properties->getProperty(idProperty); - if(idStr.empty()) - { - const char* instanceProperty = "IcePatch2.InstanceName"; - idStr = properties->getPropertyWithDefault(instanceProperty, "IcePatch2") + "/server"; - } - const Identity id = communicator->stringToIdentity(idStr); + Identity id; + id.category = properties->getPropertyWithDefault("IcePatch2.InstanceName", "IcePatch2"); + id.name = "server"; - ObjectPrx serverBase = communicator->stringToProxy(communicator->identityToString(id) + ':' + endpoints); + ObjectPrx serverBase = communicator->stringToProxy("\"" + communicator->identityToString(id) + "\" :" + endpoints); FileServerPrx server = FileServerPrx::checkedCast(serverBase); if(!server) { |