diff options
author | Dwayne Boone <dwayne@zeroc.com> | 2005-09-19 17:06:45 +0000 |
---|---|---|
committer | Dwayne Boone <dwayne@zeroc.com> | 2005-09-19 17:06:45 +0000 |
commit | f03fbc1d047e79e6b5dbf2b28e737b5db90c3da0 (patch) | |
tree | eab0577aaa113265d1309d55c5812a650eb77f62 /cpp/src | |
parent | fix typo in makedist script (diff) | |
download | ice-f03fbc1d047e79e6b5dbf2b28e737b5db90c3da0.tar.bz2 ice-f03fbc1d047e79e6b5dbf2b28e737b5db90c3da0.tar.xz ice-f03fbc1d047e79e6b5dbf2b28e737b5db90c3da0.zip |
Back out change
Diffstat (limited to 'cpp/src')
-rw-r--r-- | cpp/src/Ice/OutgoingAsync.cpp | 23 | ||||
-rw-r--r-- | cpp/src/slice2cpp/Gen.cpp | 10 | ||||
-rwxr-xr-x | cpp/src/slice2cs/Gen.cpp | 8 | ||||
-rw-r--r-- | cpp/src/slice2java/Gen.cpp | 8 | ||||
-rwxr-xr-x | cpp/src/slice2vb/Gen.cpp | 4 |
5 files changed, 22 insertions, 31 deletions
diff --git a/cpp/src/Ice/OutgoingAsync.cpp b/cpp/src/Ice/OutgoingAsync.cpp index c335120934b..736d4b4f28b 100644 --- a/cpp/src/Ice/OutgoingAsync.cpp +++ b/cpp/src/Ice/OutgoingAsync.cpp @@ -177,14 +177,9 @@ IceInternal::OutgoingAsync::__finished(BasicStream& is) assert(status == DispatchOK || status == DispatchUserException); - // - // It is possible for __response to trigger a retry. - // If it does we must not perform a cleanup. - // - bool retry = false; try { - retry = __response(status == DispatchOK); + __response(status == DispatchOK); } catch(const Exception& ex) { @@ -199,13 +194,10 @@ IceInternal::OutgoingAsync::__finished(BasicStream& is) warning(); } - if(!retry) - { - cleanup(); - } + cleanup(); } -bool +void IceInternal::OutgoingAsync::__finished(const LocalException& exc) { IceUtil::Monitor<IceUtil::RecMutex>::Lock sync(_monitor); @@ -252,7 +244,7 @@ IceInternal::OutgoingAsync::__finished(const LocalException& exc) { _connection = 0; __send(); - return true; + return; } } @@ -274,7 +266,6 @@ IceInternal::OutgoingAsync::__finished(const LocalException& exc) } cleanup(); - return false; } void @@ -470,7 +461,7 @@ Ice::AMI_Object_ice_invoke::__invoke(const ObjectPrx& prx, const string& operati __send(); } -bool +void Ice::AMI_Object_ice_invoke::__response(bool ok) // ok == true means no user exception. { vector<Byte> outParams; @@ -481,8 +472,8 @@ Ice::AMI_Object_ice_invoke::__response(bool ok) // ok == true means no user exce } catch(const LocalException& ex) { - return __finished(ex); + __finished(ex); + return; } ice_response(ok, outParams); - return false; } diff --git a/cpp/src/slice2cpp/Gen.cpp b/cpp/src/slice2cpp/Gen.cpp index 930fee15337..0691a80505c 100644 --- a/cpp/src/slice2cpp/Gen.cpp +++ b/cpp/src/slice2cpp/Gen.cpp @@ -4143,7 +4143,7 @@ Slice::Gen::AsyncVisitor::visitOperation(const OperationPtr& p) H << nl << "protected:"; H.inc(); H << sp; - H << nl << "virtual bool __response(bool);"; + H << nl << "virtual void __response(bool);"; H << eb << ';'; H << sp << nl << "typedef ::IceUtil::Handle< " << classScopedAMI << '_' << name << "> " << classNameAMI << '_' << name << "Ptr;"; @@ -4173,7 +4173,7 @@ Slice::Gen::AsyncVisitor::visitOperation(const OperationPtr& p) C << nl << "__send();"; C << eb; - C << sp << nl << "bool" << nl << classScopedAMI.substr(2) << '_' << name << "::__response(bool __ok)"; + C << sp << nl << "void" << nl << classScopedAMI.substr(2) << '_' << name << "::__response(bool __ok)"; C << sb; writeAllocateCode(C, outParams, ret); C << nl << "try"; @@ -4202,7 +4202,7 @@ Slice::Gen::AsyncVisitor::visitOperation(const OperationPtr& p) C << nl << "catch(const " << fixKwd((*i)->scoped()) << "& __ex)"; C << sb; C << nl << "ice_exception(__ex);"; - C << nl << "return false;"; + C << nl << "return;"; C << eb; } C << nl << "catch(const ::Ice::UserException& __ex)"; @@ -4219,10 +4219,10 @@ Slice::Gen::AsyncVisitor::visitOperation(const OperationPtr& p) C << eb; C << nl << "catch(const ::Ice::LocalException& __ex)"; C << sb; - C << nl << "return __finished(__ex);"; + C << nl << "__finished(__ex);"; + C << nl << "return;"; C << eb; C << nl << "ice_response" << spar << args << epar << ';'; - C << nl << "return false;"; C << eb; } diff --git a/cpp/src/slice2cs/Gen.cpp b/cpp/src/slice2cs/Gen.cpp index f4076043d09..bd9132b0fe2 100755 --- a/cpp/src/slice2cs/Gen.cpp +++ b/cpp/src/slice2cs/Gen.cpp @@ -4304,7 +4304,7 @@ Slice::Gen::AsyncVisitor::visitOperation(const OperationPtr& p) _out << nl << "__send();"; _out << eb; - _out << sp << nl << "protected override bool __response(bool __ok)"; + _out << sp << nl << "protected override void __response(bool __ok)"; _out << sb; for(q = outParams.begin(); q != outParams.end(); ++q) { @@ -4386,18 +4386,18 @@ Slice::Gen::AsyncVisitor::visitOperation(const OperationPtr& p) _out << eb; _out << nl << "catch(Ice.LocalException __ex)"; _out << sb; - _out << nl << "return __finished(__ex);"; + _out << nl << "__finished(__ex);"; + _out << nl << "return;"; _out << eb; if(!throws.empty()) { _out << nl << "catch(Ice.UserException __ex)"; _out << sb; _out << nl << "ice_exception(__ex);"; - _out << nl << "return false;"; + _out << nl << "return;"; _out << eb; } _out << nl << "ice_response" << spar << args << epar << ';'; - _out << nl << "return false;"; _out << eb; _out << eb; } diff --git a/cpp/src/slice2java/Gen.cpp b/cpp/src/slice2java/Gen.cpp index a6a6208639f..b32e85a4e08 100644 --- a/cpp/src/slice2java/Gen.cpp +++ b/cpp/src/slice2java/Gen.cpp @@ -4438,7 +4438,7 @@ Slice::Gen::AsyncVisitor::visitOperation(const OperationPtr& p) out << nl << "__send();"; out << eb; - out << sp << nl << "protected final boolean" << nl << "__response(boolean __ok)"; + out << sp << nl << "protected final void" << nl << "__response(boolean __ok)"; out << sb; for(pli = outParams.begin(); pli != outParams.end(); ++pli) { @@ -4481,7 +4481,7 @@ Slice::Gen::AsyncVisitor::visitOperation(const OperationPtr& p) out << nl << "catch(" << getAbsolute(*r, classPkg) << " __ex)"; out << sb; out << nl << "ice_exception(__ex);"; - out << nl << "return false;"; + out << nl << "return;"; out << eb; } out << nl << "catch(Ice.UserException __ex)"; @@ -4523,10 +4523,10 @@ Slice::Gen::AsyncVisitor::visitOperation(const OperationPtr& p) out << eb; out << nl << "catch(Ice.LocalException __ex)"; out << sb; - out << nl << "return __finished(__ex);"; + out << nl << "__finished(__ex);"; + out << nl << "return;"; out << eb; out << nl << "ice_response" << spar << args << epar << ';'; - out << nl << "return false;"; out << eb; out << eb; diff --git a/cpp/src/slice2vb/Gen.cpp b/cpp/src/slice2vb/Gen.cpp index 7e59807ec95..7bd01a9bede 100755 --- a/cpp/src/slice2vb/Gen.cpp +++ b/cpp/src/slice2vb/Gen.cpp @@ -4838,7 +4838,7 @@ Slice::Gen::AsyncVisitor::visitOperation(const OperationPtr& p) _out.dec(); _out << nl << "End Sub"; - _out << sp << nl << "Protected Overrides Function __response(__ok As Boolean) As Boolean"; + _out << sp << nl << "Protected Overrides Sub __response(__ok As Boolean) As Boolean"; _out.inc(); for(q = outParams.begin(); q != outParams.end(); ++q) { @@ -4936,7 +4936,7 @@ Slice::Gen::AsyncVisitor::visitOperation(const OperationPtr& p) _out << nl << "ice_response" << spar << args << epar; _out << nl << "Return False"; _out.dec(); - _out << nl << "End Function"; + _out << nl << "End Sub"; _out.dec(); _out << nl << "End Class"; } |