nginx-0.0.3-2004-04-13-09:27:03 import
diff --git a/src/http/modules/proxy/ngx_http_proxy_handler.c b/src/http/modules/proxy/ngx_http_proxy_handler.c
index 84c9264..017d7c8 100644
--- a/src/http/modules/proxy/ngx_http_proxy_handler.c
+++ b/src/http/modules/proxy/ngx_http_proxy_handler.c
@@ -425,6 +425,10 @@
 
     n = recv(c->fd, buf, 1, MSG_PEEK);
 
+    if (ev->write && n >= 0) {
+        return;
+    }
+
     if (n > 0) {
         if ((ngx_event_flags & NGX_USE_LEVEL_EVENT) && ev->active) {
             if (ngx_del_event(ev, NGX_READ_EVENT, 0) == NGX_ERROR) {