Commit 288d5916 authored by Kai Vehmanen's avatar Kai Vehmanen

nua: Ignore CANCEL of incoming request if we have already sent a final...

nua: Ignore CANCEL of incoming request if we have already sent a final response. Problem reported by Mike Jerris.

darcs-hash:20070212230200-7659e-b45cc5b2242a4aa9195c5ee1443784ad43d9708f.gz
parent 162bb38e
......@@ -2199,15 +2199,16 @@ int process_cancel(nua_server_request_t *sr,
msg_t *cancel = nta_incoming_getrequest_ackcancel(irq);
assert(nta_incoming_status(irq) < 200);
assert(nua_server_request_is_pending(sr));
assert(ss); assert(ss == nua_session_usage_get(nh->nh_ds)); (void)ss;
nua_stack_event(nh->nh_nua, nh, cancel, nua_i_cancel, SIP_200_OK, NULL);
if (nua_server_request_is_pending(sr)) {
nua_stack_event(nh->nh_nua, nh, cancel, nua_i_cancel, SIP_200_OK, NULL);
SR_STATUS1(sr, SIP_487_REQUEST_TERMINATED);
SR_STATUS1(sr, SIP_487_REQUEST_TERMINATED);
nua_server_respond(sr, NULL);
nua_server_report(sr);
nua_server_respond(sr, NULL);
nua_server_report(sr);
}
return 0;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment