[asterisk-dev] [Code Review]: Bug fixes for voicemail user emailsubject / emailbody

mjordan reviewboard at asterisk.org
Thu Aug 25 14:22:54 CDT 2011



> On Aug. 25, 2011, 2:09 p.m., rmudgett wrote:
> > /branches/10/apps/app_voicemail.c, lines 1455-1461
> > <https://reviewboard.asterisk.org/r/1374/diff/2/?file=18584#file18584line1455>
> >
> >     This must be a deep copy to prevent double frees of malloced elements like emailbody when the original and copy are destroyed.  This currently a shallow copy where only the top level values are copied.  For elements like emailbody, only the pointer is currently copied.
> >     
> >     The deep copy must be done if the vmu is malloced here.  The shallow copy must be done if not malloced here.
> >     
> >     The treatment of static struct ast_vm_user structures is ripe with memory problems dealing with strings like emailbody.

I'll fix this before I put this in as well.

I agree on the 'tip of the ice-burg' problems in here.  The longer term efforts on app_voicemail should address these concerns.


- mjordan


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviewboard.asterisk.org/r/1374/#review4130
-----------------------------------------------------------


On Aug. 24, 2011, 2:56 p.m., mjordan wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviewboard.asterisk.org/r/1374/
> -----------------------------------------------------------
> 
> (Updated Aug. 24, 2011, 2:56 p.m.)
> 
> 
> Review request for Asterisk Developers and kmoore.
> 
> 
> Summary
> -------
> 
> This code change fixes two bugs:
> ASTERISK-16795
> ASTERISK-16781
> 
> ASTERISK-16795 was previously fixed in the last iteration and patched to 1.8 and trunk.  Unfortunately, a subsequent check-in blew out the change, removing it from 10 and trunk (10 being subsequently branched off of what was, at the time, trunk).  The previous fix for ASTERISK-16795 resolved most of ASTERISK-16781 - this code change fixes the rest of ASTERISK-16781 by applying escape options to all places voicemail user options are parsed out.
> 
> In order to complete this, the relevant code change in apply_options_full will be ported back to 1.8; the rest of these code changes are already in that branch.
> 
> 
> This addresses bugs ASTERISK-16781 and ASTERISK-16795;.
>     https://issues.asterisk.org/jira/browse/ASTERISK-16781
>     https://issues.asterisk.org/jira/browse/ASTERISK-16795;
> 
> 
> Diffs
> -----
> 
>   /branches/10/apps/app_voicemail.c 333159 
> 
> Diff: https://reviewboard.asterisk.org/r/1374/diff
> 
> 
> Testing
> -------
> 
> vmuser unit test updated and ran successfully.
> 
> 
> Thanks,
> 
> mjordan
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20110825/24d11c4a/attachment-0001.htm>


More information about the asterisk-dev mailing list