[svn-commits] rmudgett: branch 12 r423894 - /branches/12/res/res_pjsip.c
SVN commits to the Digium repositories
svn-commits at lists.digium.com
Thu Sep 25 16:00:13 CDT 2014
Author: rmudgett
Date: Thu Sep 25 16:00:08 2014
New Revision: 423894
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=423894
Log:
res_pjsip.c: Add missing off nominal cleanup in ast_sip_push_task_synchronous().
* Made memset the std struct in ast_sip_push_task_synchronous() because if
DEBUG_THREADS is enabled then uninitialized lock tracking data is used.
Modified:
branches/12/res/res_pjsip.c
Modified: branches/12/res/res_pjsip.c
URL: http://svnview.digium.com/svn/asterisk/branches/12/res/res_pjsip.c?view=diff&rev=423894&r1=423893&r2=423894
==============================================================================
--- branches/12/res/res_pjsip.c (original)
+++ branches/12/res/res_pjsip.c Thu Sep 25 16:00:08 2014
@@ -2241,18 +2241,22 @@
return sip_task(task_data);
}
+ memset(&std, 0, sizeof(std));
ast_mutex_init(&std.lock);
ast_cond_init(&std.cond, NULL);
- std.fail = std.complete = 0;
std.task = sip_task;
std.task_data = task_data;
if (serializer) {
if (ast_taskprocessor_push(serializer, sync_task, &std)) {
+ ast_mutex_destroy(&std.lock);
+ ast_cond_destroy(&std.cond);
return -1;
}
} else {
if (ast_threadpool_push(sip_threadpool, sync_task, &std)) {
+ ast_mutex_destroy(&std.lock);
+ ast_cond_destroy(&std.cond);
return -1;
}
}
More information about the svn-commits
mailing list