Merged revisions 164736 via svnmerge from
authorRussell Bryant <russell@russellbryant.com>
Tue, 16 Dec 2008 17:14:01 +0000 (17:14 +0000)
committerRussell Bryant <russell@russellbryant.com>
Tue, 16 Dec 2008 17:14:01 +0000 (17:14 +0000)
commit556b08252289bdabef3930b492ee013a4c317c83
treedcb6a2481818394e37619343066de2a1bbcef8ff
parent601176cb6ebd7f713a4548ba60c4644585cdb415
Merged revisions 164736 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r164736 | russell | 2008-12-16 11:06:29 -0600 (Tue, 16 Dec 2008) | 14 lines

Fix memory leak and invalid reporting issues with DEBUG_THREADLOCALS.

One issue was that the ast_mutex_* API was being used within the context of the
thread local data destructors.  We would go off and allocate more thread local data
while the pthread lib was in the middle of destroying it all.  This led to a memory
leak.

Another issue was an invalid argument being provided to the the object_add
API call.

(closes issue #13678)
Reported by: ys
Tested by: Russell

........

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@164737 65c4cc65-6c06-0410-ace0-fbb531ad65f3
include/asterisk/threadstorage.h
main/threadstorage.c