handle errors in processing INVITE

sayer/1.4-spce2.6
Stefan Sayer 16 years ago
parent e9eae2154e
commit 9503de2971

@ -721,7 +721,19 @@ void AmSession::onSipRequest(const AmSipRequest& req)
break;
}
onInvite(req);
try {
onInvite(req);
}
catch(const string& s) {
ERROR("%s\n",s.c_str());
setStopped();
AmSipDialog::reply_error(req, 500, "Internal Server Error");
}
catch(const AmSession::Exception& e) {
ERROR("%i %s\n",e.code,e.reason.c_str());
setStopped();
AmSipDialog::reply_error(req,e.code,e.reason);
}
if(detached.get() && !getStopped()){

Loading…
Cancel
Save