Skip to content

Commit 27848ed

Browse files
Add comment about async pipelining
1 parent 933b984 commit 27848ed

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/HttpContext.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,9 @@ struct HttpContext {
149149
HttpResponseData<SSL> *httpResponseData = (HttpResponseData<SSL> *) us_socket_ext(SSL, (us_socket_t *) s);
150150
httpResponseData->offset = 0;
151151

152-
/* Are we not ready for another request yet? Terminate the connection. */
152+
/* Are we not ready for another request yet? Terminate the connection.
153+
* Important for denying async pipelining until, if ever, we want to suppot it.
154+
* Otherwise requests can get mixed up on the same connection. We still support sync pipelining. */
153155
if (httpResponseData->state & HttpResponseData<SSL>::HTTP_RESPONSE_PENDING) {
154156
us_socket_close(SSL, (us_socket_t *) s, 0, nullptr);
155157
return nullptr;

0 commit comments

Comments
 (0)