don't destroy calls when re-INVITE messages ask for things we can't do (issue #5384)

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6714 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Kevin P. Fleming 2005-10-04 22:09:23 +00:00
parent dea1d768f9
commit a0a478a72c
1 changed files with 4 additions and 2 deletions

View File

@ -10103,7 +10103,8 @@ static int handle_request_invite(struct sip_pvt *p, struct sip_request *req, int
if (required_profile) { /* They require something */
/* At this point we support no extensions, so fail */
transmit_response_with_unsupported(p, "420 Bad extension", req, required);
ast_set_flag(p, SIP_NEEDDESTROY);
if (!p->lastinvite)
ast_set_flag(p, SIP_NEEDDESTROY);
return -1;
}
@ -10136,7 +10137,8 @@ static int handle_request_invite(struct sip_pvt *p, struct sip_request *req, int
if (!strcasecmp(get_header(req, "Content-Type"), "application/sdp")) {
if (process_sdp(p, req)) {
transmit_response(p, "488 Not acceptable here", req);
ast_set_flag(p, SIP_NEEDDESTROY);
if (!p->lastinvite)
ast_set_flag(p, SIP_NEEDDESTROY);
return -1;
}
} else {