diff src/os/unix/ngx_linux_sendfile_chain.c @ 7239:400a3412b1e3

Fixed checking ngx_tcp_push() and ngx_tcp_nopush() return values. No functional changes.
author Ruslan Ermilov <ru@nginx.com>
date Mon, 19 Mar 2018 16:28:23 +0300
parents ff0c8e11edbc
children a2613fc1bce5
line wrap: on
line diff
--- a/src/os/unix/ngx_linux_sendfile_chain.c
+++ b/src/os/unix/ngx_linux_sendfile_chain.c
@@ -130,7 +130,7 @@ ngx_linux_sendfile_chain(ngx_connection_
 
             if (c->tcp_nodelay == NGX_TCP_NODELAY_UNSET) {
 
-                if (ngx_tcp_nopush(c->fd) == NGX_ERROR) {
+                if (ngx_tcp_nopush(c->fd) == -1) {
                     err = ngx_socket_errno;
 
                     /*