[asterisk-commits] wdoekes: branch 12 r414678 - in /branches/12: ./ channels/chan_unistim.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Wed May 28 04:43:09 CDT 2014


Author: wdoekes
Date: Wed May 28 04:43:03 2014
New Revision: 414678

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=414678
Log:
chan_unistim: Unlock mutex in rare OOM condition.

#ASTERISK-23792 #close
Reported by: Peter Whisker

Review: https://reviewboard.asterisk.org/r/3567/
........

Merged revisions 414677 from http://svn.asterisk.org/svn/asterisk/branches/11

Modified:
    branches/12/   (props changed)
    branches/12/channels/chan_unistim.c

Propchange: branches/12/
------------------------------------------------------------------------------
Binary property 'branch-11-merged' - no diff available.

Modified: branches/12/channels/chan_unistim.c
URL: http://svnview.digium.com/svn/asterisk/branches/12/channels/chan_unistim.c?view=diff&rev=414678&r1=414677&r2=414678
==============================================================================
--- branches/12/channels/chan_unistim.c (original)
+++ branches/12/channels/chan_unistim.c Wed May 28 04:43:03 2014
@@ -6257,10 +6257,10 @@
 		}
 		d = d->next;
 	}
+	ast_mutex_unlock(&devicelock);
 	if (!(lt = ast_calloc(1, sizeof(*lt)))) {
 		return NULL;
 	}
-	ast_mutex_unlock(&devicelock);
 	if (create) {
 		if (!(d = ast_calloc(1, sizeof(*d)))) {
 			return NULL;




More information about the asterisk-commits mailing list