summaryrefslogtreecommitdiff
path: root/cpp/src/Ice/Instance.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'cpp/src/Ice/Instance.cpp')
-rw-r--r--cpp/src/Ice/Instance.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/cpp/src/Ice/Instance.cpp b/cpp/src/Ice/Instance.cpp
index 0b3756b7e5e..57fba4dfdb8 100644
--- a/cpp/src/Ice/Instance.cpp
+++ b/cpp/src/Ice/Instance.cpp
@@ -505,9 +505,12 @@ IceInternal::Instance::Instance(const CommunicatorPtr& communicator, const Prope
Int num = _properties->getPropertyAsIntWithDefault("Ice.ConnectionIdleTime", 60);
if(num < 0)
{
- num = 0;
+ const_cast<Int&>(_connectionIdleTime) = 0;
+ }
+ else
+ {
+ const_cast<Int&>(_connectionIdleTime) = num;
}
- const_cast<Int&>(_connectionIdleTime) = num;
}
_routerManager = new RouterManager;