diff options
author | Michi Henning <michi@zeroc.com> | 2008-05-08 15:06:13 +1000 |
---|---|---|
committer | Michi Henning <michi@zeroc.com> | 2008-05-08 15:06:13 +1000 |
commit | d74d3d2b2f443a46825292475227be42279d4476 (patch) | |
tree | 2eda600511121b9f4fd70396ffd2ff3b6b9ad507 /cpp/demo/Ice/nested/Client.cpp | |
parent | Fixed bug 3102 (diff) | |
download | ice-d74d3d2b2f443a46825292475227be42279d4476.tar.bz2 ice-d74d3d2b2f443a46825292475227be42279d4476.tar.xz ice-d74d3d2b2f443a46825292475227be42279d4476.zip |
Bug 3097 - Smart pointer formal parameter not exception safe
Diffstat (limited to 'cpp/demo/Ice/nested/Client.cpp')
-rw-r--r-- | cpp/demo/Ice/nested/Client.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/cpp/demo/Ice/nested/Client.cpp b/cpp/demo/Ice/nested/Client.cpp index 102b80fb413..c8b11636da3 100644 --- a/cpp/demo/Ice/nested/Client.cpp +++ b/cpp/demo/Ice/nested/Client.cpp @@ -56,7 +56,8 @@ NestedClient::run(int argc, char* argv[]) Ice::ObjectAdapterPtr adapter = communicator()->createObjectAdapter("Nested.Client"); NestedPrx self = NestedPrx::uncheckedCast(adapter->createProxy(communicator()->stringToIdentity("nestedClient"))); - adapter->add(new NestedI(self), communicator()->stringToIdentity("nestedClient")); + NestedPtr servant = new NestedI(self); + adapter->add(servant, communicator()->stringToIdentity("nestedClient")); adapter->activate(); cout << "Note: The maximum nesting level is sz * 2, with sz being\n" |