diff options
author | Richard Mudgett <rmudgett@digium.com> | 2015-06-16 15:06:22 -0500 |
---|---|---|
committer | Richard Mudgett <rmudgett@digium.com> | 2015-06-25 14:37:08 -0500 |
commit | 602c4b74b500fb6fbe3ae3f6e13d2502edbdd56c (patch) | |
tree | 3d8401a42dfc20018d3f907f1e8c0738a9118450 /Makefile | |
parent | 8c6a95a9ac605c53d1a5863528ff940221684ea3 (diff) |
res_pjsip_outbound_registration.c: Fix handle_client_state_destruction() refs
* handle_client_state_destruction() must always be passed a ref to
client_state because it will always unref client_state.
handle_registration_response() was not passing a client_state ref.
* Made the final un-REGISTER message get sent normally using the pjproject
register control structure in handle_client_state_destruction(). The
previous code attempted to short circuit the response handling for the
module to unload. That doesn't work for a couple reasons. One,
pjsip_regc_send() may call the registered callback before it returns and
unbalance the client_state ref count. Two, the registered callback
handles any authentication for the un-REGISTER message.
* Made the distinction between internal registration state and external
registration status with sip_outbound_registration_status_str(). This is
necessary to avoid altering documented AMI messages with internal
changes.
* Removed references to client_state->client outside of the serializer
thread. When handle_client_state_destruction() destroys the pjproject
register control structure that memory is freed and cannot be referenced
anymore. These accesses were to provide information for debug and
off-nominal warning messages.
* In sip_outbound_registration_timer_cb() you should not access entry->id
after unrefing client_state because the passed in entry is normally
pointing to the timer entry in the client_state object.
ASTERISK-24907
Reported by: Kevin Harwell
Change-Id: Ia7b446d8644b6b4550ef5bea49527671de65183f
Diffstat (limited to 'Makefile')
0 files changed, 0 insertions, 0 deletions