summaryrefslogtreecommitdiff
path: root/pbx
diff options
context:
space:
mode:
authorMatthew Jordan <mjordan@digium.com>2012-02-25 17:22:55 +0000
committerMatthew Jordan <mjordan@digium.com>2012-02-25 17:22:55 +0000
commit5e40f2cd98143c2e3997375db24beee54e1e70a9 (patch)
treea65af304457996ce2f3cd7e8a916550ca23449eb /pbx
parent0553e61207dce280db4d7bb1c308e1451e9b1449 (diff)
Fix crash in app_voicemail during close_mailbox
In r354890, a memory leak in app_voicemail was fixed by properly disposing of the allocated heard/deleted pointers. However, there are situations, particularly when no messages are found in a folder, where these pointers are not allocated and not NULL. In that case, an invalid free would be attempted, which could crash app_voicemail. As there are a number of code paths where this could occur, this patch uses the number of messages detected in the folder before it attempts to free the pointers. This resolves the crash detected in the Asterisk Test Suite's check_voicemail_nominal test. ........ Merged revisions 356797 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 356798 from http://svn.asterisk.org/svn/asterisk/branches/10 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@356799 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'pbx')
0 files changed, 0 insertions, 0 deletions