[Asterisk-code-review] res pjsip: Fix leak on error in ast sip auth vector init. (asterisk[13])

Corey Farrell asteriskteam at digium.com
Mon Nov 6 17:31:51 CST 2017


Corey Farrell has uploaded this change for review. ( https://gerrit.asterisk.org/7063


Change subject: res_pjsip: Fix leak on error in ast_sip_auth_vector_init.
......................................................................

res_pjsip: Fix leak on error in ast_sip_auth_vector_init.

Change-Id: Ib0fc7a18f3135ca8990c3984c9e15f6d26e556e8
---
M res/res_pjsip/pjsip_configuration.c
1 file changed, 2 insertions(+), 0 deletions(-)



  git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/63/7063/1

diff --git a/res/res_pjsip/pjsip_configuration.c b/res/res_pjsip/pjsip_configuration.c
index e000039..81234d6 100644
--- a/res/res_pjsip/pjsip_configuration.c
+++ b/res/res_pjsip/pjsip_configuration.c
@@ -510,6 +510,8 @@
 			goto failure;
 		}
 		if (AST_VECTOR_APPEND(auths, val)) {
+			ast_free(val);
+
 			goto failure;
 		}
 	}

-- 
To view, visit https://gerrit.asterisk.org/7063
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: 13
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ib0fc7a18f3135ca8990c3984c9e15f6d26e556e8
Gerrit-Change-Number: 7063
Gerrit-PatchSet: 1
Gerrit-Owner: Corey Farrell <git at cfware.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20171106/b19395c7/attachment-0001.html>


More information about the asterisk-code-review mailing list