Review Board 1.7.16


Audit ast_pjsip_rdata_get_endpoint() usage for ref leaks.

Review Request #4511 - Created March 17, 2015 and submitted

rmudgett
13
Reviewers
asterisk-dev
Asterisk
Valgrind found some memory leaks associated with
ast_pjsip_rdata_get_endpoint().  The leaks would manifest when sending
responses to OPTIONS requests, processing MESSAGE requests, and
res_pjsip supplements implementing the incoming_request callback.

* Fix ast_pjsip_rdata_get_endpoint() endpoint ref leaks in
res/res_pjsip.c:supplement_on_rx_request(),
res/res_pjsip/pjsip_options.c:send_options_response(),
res/res_pjsip_messaging.c:rx_data_to_ast_msg(), and
res/res_pjsip_messaging.c:send_response().

* Eliminated RAII_VAR() use with ast_pjsip_rdata_get_endpoint() in
res/res_pjsip_nat.c:nat_on_rx_message().

* Fixed inconsistent but benign return value in
res/res_pjsip/pjsip_options.c:options_on_rx_request().
Added temporary logging messages to show that incoming OPTIONS and MESSAGE
requests hit the code that leaked the endpoint object refs.
Total:
1
Open:
0
Resolved:
1
Dropped:
0
Status:
From:
Review request changed
Updated (March 20, 2015, 3:24 p.m.)
  • changed from pending to submitted
Committed in revision 433243

https://reviewboard.asterisk.org/ runs on a server provided by Digium, Inc. and uses bandwidth donated to the open source Asterisk community by API Digital Communications in Huntsville, AL USA.
Please report problems with this site to asteriskteam@digium.com.