[MINOR] http: detect tunnel mode and set it in the session

In order to support keepalive, we'll have to differentiate
normal sessions from tunnel sessions, which are the ones we
don't want to analyse further.

Those are typically the CONNECT requests where we don't care
about any form of content-length, as well as the requests
which are forwarded on non-close and non-keepalive proxies.
diff --git a/src/proto_http.c b/src/proto_http.c
index 10874c5..e4662a3 100644
--- a/src/proto_http.c
+++ b/src/proto_http.c
@@ -2611,6 +2611,15 @@
 		}
 	}
 
+
+	/* indicate in the session if it will be a tunnel-mode one or not. If
+	 * we don't intend to analyse contents after the first request, it's a
+	 * tunnel.
+	 */
+	if (s->txn.meth == HTTP_METH_CONNECT ||
+	    !((s->fe->options|s->be->options) & (PR_O_KEEPALIVE|PR_O_HTTP_CLOSE|PR_O_FORCE_CLO)))
+		s->flags |= SN_TUNNEL;
+
 	/* 11: add "Connection: close" if needed and not yet set. */
 	if (!(s->flags & SN_CONN_CLOSED) &&
 	    ((s->fe->options | s->be->options) & (PR_O_HTTP_CLOSE|PR_O_FORCE_CLO))) {