Explicitly set a variable to 1 instead of using the increment operator.
authorRussell Bryant <russell@russellbryant.com>
Mon, 30 Jul 2007 20:33:44 +0000 (20:33 +0000)
committerRussell Bryant <russell@russellbryant.com>
Mon, 30 Jul 2007 20:33:44 +0000 (20:33 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77799 65c4cc65-6c06-0410-ace0-fbb531ad65f3

channels/chan_iax2.c

index b729cab..1709d87 100644 (file)
@@ -2006,7 +2006,7 @@ static void __attempt_transmit(void *data)
        /* Attempt to transmit the frame to the remote peer...
           Called without iaxsl held. */
        struct iax_frame *f = data;
-       int freeme=0;
+       int freeme = 0;
        int callno = f->callno;
        /* Make sure this call is still active */
        if (callno) 
@@ -2046,7 +2046,7 @@ static void __attempt_transmit(void *data)
                                        }
 
                                }
-                               freeme++;
+                               freeme = 1;
                } else {
                        /* Update it if it needs it */
                        update_packet(f);
@@ -2065,7 +2065,7 @@ static void __attempt_transmit(void *data)
        } else {
                /* Make sure it gets freed */
                f->retries = -1;
-               freeme++;
+               freeme = 1;
        }
        if (callno)
                ast_mutex_unlock(&iaxsl[callno]);