Re #1526: r4175 missed PJSUA_UNLOCK() on some failure cases in pjsua_call_answer2().

git-svn-id: https://svn.pjsip.org/repos/pjproject/trunk@4176 74dad513-b988-da41-8d7b-12977e46ad98
This commit is contained in:
Nanang Izzuddin 2012-06-23 03:06:52 +00:00
parent 4f83b76a61
commit 00584d48c6
1 changed files with 4 additions and 1 deletions

View File

@ -2009,9 +2009,12 @@ PJ_DEF(pj_status_t) pjsua_call_answer2(pjsua_call_id call_id,
&on_answer_call_med_tp_complete);
if (status == PJ_SUCCESS) {
status = on_answer_call_med_tp_complete(call->index, NULL);
if (status != PJ_SUCCESS)
if (status != PJ_SUCCESS) {
PJSUA_UNLOCK();
goto on_return;
}
} else if (status != PJ_EPENDING) {
PJSUA_UNLOCK();
pjsua_perror(THIS_FILE, "Error initializing media channel", status);
goto on_return;
}