0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-11-19 00:10:59 +01:00

ircd::resource: Involve a request context interrupt on timeout.

This commit is contained in:
Jason Volk 2018-05-28 00:31:48 -07:00
parent 9714d1ee15
commit 54f08c0351

View file

@ -317,6 +317,12 @@ ircd::resource::operator()(client &client,
head.path
};
// The interrupt is effective when the socket has already been
// closed and/or the client is still stuck in a request for
// some reason.
if(client.reqctx)
ctx::interrupt(*client.reqctx);
//TODO: If we know that no response has been sent yet
//TODO: we can respond with http::REQUEST_TIMEOUT instead.
client.close(net::dc::RST, net::close_ignore);