summaryrefslogtreecommitdiff
path: root/objective-c/src
diff options
context:
space:
mode:
Diffstat (limited to 'objective-c/src')
-rw-r--r--objective-c/src/Ice/Proxy.mm45
1 files changed, 27 insertions, 18 deletions
diff --git a/objective-c/src/Ice/Proxy.mm b/objective-c/src/Ice/Proxy.mm
index 173a09638bd..2a797da129a 100644
--- a/objective-c/src/Ice/Proxy.mm
+++ b/objective-c/src/Ice/Proxy.mm
@@ -90,15 +90,18 @@ void completed(const Ice::AsyncResultPtr& result)
else
{
Ice::InputStreamPtr s = Ice::createInputStream(proxy->ice_getCommunicator(), outParams);
- try
+ is = [ICEInputStream localObjectWithCxxObjectNoAutoRelease:s.get()];
+ @try
{
- s->startEncapsulation();
- s->throwException();
+ [is startEncapsulation];
+ [is throwException];
}
- catch(const Ice::UserException& ex)
+ @catch(ICEUserException* ex)
{
- s->endEncapsulation();
- throw Ice::UnknownUserException(__FILE__, __LINE__, ex.ice_name());
+ [is endEncapsulation];
+ [is release];
+ is = nil;
+ nsex = [ICEUnknownUserException unknownUserException:__FILE__ line:__LINE__ unknown:[ex ice_name]];
}
}
}
@@ -550,15 +553,18 @@ BOOL _returnsData;
else
{
Ice::InputStreamPtr s = Ice::createInputStream(OBJECTPRX->ice_getCommunicator(), outParams);
- try
+ is = [ICEInputStream localObjectWithCxxObjectNoAutoRelease:s.get()];
+ @try
{
- s->startEncapsulation();
- s->throwException();
+ [is startEncapsulation];
+ [is throwException];
}
- catch(const Ice::UserException& ex)
+ @catch(ICEUserException* ex)
{
- s->endEncapsulation();
- throw Ice::UnknownUserException(__FILE__, __LINE__, ex.ice_name());
+ [is endEncapsulation];
+ [is release];
+ is = nil;
+ nsex = [ICEUnknownUserException unknownUserException:__FILE__ line:__LINE__ unknown:[ex ice_name]];
}
}
}
@@ -863,15 +869,18 @@ BOOL _returnsData;
else
{
Ice::InputStreamPtr s = Ice::createInputStream(OBJECTPRX->ice_getCommunicator(), outParams);
- try
+ is = [ICEInputStream localObjectWithCxxObjectNoAutoRelease:s.get()];
+ @try
{
- s->startEncapsulation();
- s->throwException();
+ [is startEncapsulation];
+ [is throwException];
}
- catch(const Ice::UserException& ex)
+ @catch(ICEUserException* ex)
{
- s->endEncapsulation();
- throw Ice::UnknownUserException(__FILE__, __LINE__, ex.ice_name());
+ [is endEncapsulation];
+ [is release];
+ is = nil;
+ nsex = [ICEUnknownUserException unknownUserException:__FILE__ line:__LINE__ unknown:[ex ice_name]];
}
}
}