diff options
author | Benoit Foucher <benoit@zeroc.com> | 2008-03-27 10:48:32 +0100 |
---|---|---|
committer | Benoit Foucher <benoit@zeroc.com> | 2008-03-27 10:48:32 +0100 |
commit | a78ae7816927dcbccd3db0db1014265dff19dbea (patch) | |
tree | 0b0c0f8ce3dd5e79773f70d7994a7bcd6e0adb00 /cpp/src/IceGrid/Client.cpp | |
parent | updated dependencies. (diff) | |
download | ice-a78ae7816927dcbccd3db0db1014265dff19dbea.tar.bz2 ice-a78ae7816927dcbccd3db0db1014265dff19dbea.tar.xz ice-a78ae7816927dcbccd3db0db1014265dff19dbea.zip |
Fixed bug in icegridadmin which would cause it to spin if the session timeout = 0
Diffstat (limited to 'cpp/src/IceGrid/Client.cpp')
-rw-r--r-- | cpp/src/IceGrid/Client.cpp | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/cpp/src/IceGrid/Client.cpp b/cpp/src/IceGrid/Client.cpp index 57b37602460..f6fa90dff6c 100644 --- a/cpp/src/IceGrid/Client.cpp +++ b/cpp/src/IceGrid/Client.cpp @@ -572,9 +572,12 @@ Client::run(int argc, char* argv[]) return EXIT_FAILURE; } - keepAlive = new SessionKeepAliveThread(session, timeout / 2); - keepAlive->start(); - + if(timeout > 0) + { + keepAlive = new SessionKeepAliveThread(session, timeout / 2); + keepAlive->start(); + } + AdminPrx admin = session->getAdmin(); Ice::SliceChecksumDict serverChecksums = admin->getSliceChecksums(); @@ -653,8 +656,11 @@ Client::run(int argc, char* argv[]) throw; } - keepAlive->destroy(); - keepAlive->getThreadControl().join(); + if(keepAlive) + { + keepAlive->destroy(); + keepAlive->getThreadControl().join(); + } if(session) { |