[asterisk-dev] [asterisk-commits] file: trunk r71425 - in /trunk: ./ main/cdr.c
Steve Murphy
murf at parsetree.com
Mon Jun 25 11:44:06 CDT 2007
Luigi--
Excellent suggestion. Done, in 71637.
murf
On Sun, 2007-06-24 at 22:57 -0700, Luigi Rizzo wrote:
> On Mon, Jun 25, 2007 at 01:08:22AM -0000, SVN commits to the Asterisk project wrote:
> ...
> > Modified: trunk/main/cdr.c
> > URL: http://svn.digium.com/view/asterisk/trunk/main/cdr.c?view=diff&rev=71425&r1=71424&r2=71425
> > ==============================================================================
> > --- trunk/main/cdr.c (original)
> > +++ trunk/main/cdr.c Sun Jun 24 20:08:22 2007
> > @@ -528,7 +528,7 @@
> > if (ast_test_flag(from, AST_CDR_FLAG_LOCKED)) {
> > discard_from = 1;
> > if (lto) {
> > - struct ast_cdr *llfrom;
> > + struct ast_cdr *llfrom = NULL;
> > /* insert the from stuff after lto */
> > lto->next = from;
> > lfrom = from;
> > @@ -543,7 +543,7 @@
> > } else {
> > /* save copy of the current *to cdr */
> > struct ast_cdr tcdr;
> > - struct ast_cdr *llfrom;
> > + struct ast_cdr *llfrom = NULL;
> > memcpy(&tcdr, to, sizeof(tcdr));
> > /* copy in the locked from cdr */
> > memcpy(to, from, sizeof(*to));
>
> you can probably bring the declaration of llfrom right before
> discard_from = 1;
> since the variable is used in both branches of the if/then/else
>
> cheers
> luigi
>
> _______________________________________________
> --Bandwidth and Colocation Provided by http://www.api-digital.com--
>
> asterisk-dev mailing list
> To UNSUBSCRIBE or update options visit:
> http://lists.digium.com/mailman/listinfo/asterisk-dev
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 3239 bytes
Desc: not available
Url : http://lists.digium.com/pipermail/asterisk-dev/attachments/20070625/26815712/attachment.bin
More information about the asterisk-dev
mailing list