diff src/os/win32/ngx_wsasend_chain.c @ 5851:150df089fe47

Removed the "complete" variable from various send chain functions. It was made redundant by the previous change, since the "sent" variable is no longer modified.
author Valentin Bartenev <vbart@nginx.com>
date Wed, 13 Aug 2014 15:11:45 +0400
parents f9c83484d9ce
children a6e83ac70af9
line wrap: on
line diff
--- a/src/os/win32/ngx_wsasend_chain.c
+++ b/src/os/win32/ngx_wsasend_chain.c
@@ -19,7 +19,6 @@ ngx_wsasend_chain(ngx_connection_t *c, n
     int           rc;
     u_char       *prev;
     u_long        size, sent, send, prev_send;
-    ngx_uint_t    complete;
     ngx_err_t     err;
     ngx_event_t  *wev;
     ngx_array_t   vec;
@@ -40,7 +39,6 @@ ngx_wsasend_chain(ngx_connection_t *c, n
     }
 
     send = 0;
-    complete = 0;
 
     /*
      * WSABUFs must be 4-byte aligned otherwise
@@ -113,15 +111,11 @@ ngx_wsasend_chain(ngx_connection_t *c, n
         ngx_log_debug2(NGX_LOG_DEBUG_EVENT, c->log, 0,
                        "WSASend: fd:%d, s:%ul", c->fd, sent);
 
-        if (send - prev_send == sent) {
-            complete = 1;
-        }
-
         c->sent += sent;
 
         cl = ngx_handle_sent_chain(in, sent);
 
-        if (!complete) {
+        if (send - prev_send != sent) {
             wev->ready = 0;
             return cl;
         }