Hi Guillaume and Willy,
Le 05/09/2014 22:05, Cyril Bonté a écrit :
Indeed, I could reproduce the issue in 100% of my tests, sending 2
requests with keep-alive enabled.
In case it helps to track the issue, I could simplify the configuration
up to :
listen test :10002
balance roundrobin
mode http
option http-server-close
http-send-name-header Host
server server-name 127.0.0.1:80
then, to reproduce the issue :
$ echo -ne "GET / HTTP/1.1\r\nHost: test\r\n\r\nGET / HTTP/1.1\r\nHost:
test\r\n\r\n" | nc localhost 10002
I think we are in a similar case as the one I tried to fix in commit
1ad838b678 [1].
I took some minutes to make some more tests and maybe I could come to a
fix for this new case, but I'm not sure it's enough and I would like to
definitely close issues on http-send-name-header in haproxy 1.4 ;-)
Willy, can you confirm that the patch attached is the only thing we need
? In my previous tests, it solves the issue.
Thanks.
[1]
http://www.haproxy.org/git?p=haproxy-1.4.git;a=commit;h=5b4d0775f0afd10c80e63842dca85a69281c9433
--
Cyril Bonté
diff --git a/src/proto_http.c b/src/proto_http.c
index 7c156ed..f4634f2 100644
--- a/src/proto_http.c
+++ b/src/proto_http.c
@@ -4076,6 +4076,7 @@ int http_send_name_header(struct http_txn *txn, struct http_msg *msg, struct buf
/* Adjust buffer data length to send */
buf->send_max -= delta;
+ txn->req.som -= delta;
return 0;
}