[asterisk-commits] may: branch may/chan_ooh323_evo r339085 - /team/may/chan_ooh323_evo/addons/oo...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Mon Oct 3 13:24:07 CDT 2011


Author: may
Date: Mon Oct  3 13:24:03 2011
New Revision: 339085

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=339085
Log:
destroy memheap mutex properly before memheap deleted
(fix memory leak introduced by r304950 with DEBUG_THREAD compile option)

Modified:
    team/may/chan_ooh323_evo/addons/ooh323c/src/memheap.c

Modified: team/may/chan_ooh323_evo/addons/ooh323c/src/memheap.c
URL: http://svnview.digium.com/svn/asterisk/team/may/chan_ooh323_evo/addons/ooh323c/src/memheap.c?view=diff&rev=339085&r1=339084&r2=339085
==============================================================================
--- team/may/chan_ooh323_evo/addons/ooh323c/src/memheap.c (original)
+++ team/may/chan_ooh323_evo/addons/ooh323c/src/memheap.c Mon Oct  3 13:24:03 2011
@@ -822,9 +822,10 @@
          free (pMemLink2);
       }
 
-      if ((*ppMemHeap)->flags & RT_MH_FREEHEAPDESC)
+      if ((*ppMemHeap)->flags & RT_MH_FREEHEAPDESC) {
+         ast_mutex_destroy(&pMemHeap->pLock);
          free (*ppMemHeap);
-
+      }
       *ppMemHeap = 0;
    }
 }




More information about the asterisk-commits mailing list