From 1dec67d81e446045a97b042ba7933ce5d4c52138 Mon Sep 17 00:00:00 2001 From: Jason Volk Date: Fri, 9 Mar 2018 10:54:29 -0800 Subject: [PATCH] ircd: Catch inner timeouts on client request. --- ircd/resource.cc | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/ircd/resource.cc b/ircd/resource.cc index 948be4cc7..442009bb5 100644 --- a/ircd/resource.cc +++ b/ircd/resource.cc @@ -345,6 +345,13 @@ catch(const std::out_of_range &e) http::NOT_FOUND, "M_NOT_FOUND", "%s", e.what() }; } +catch(const ctx::timeout &e) +{ + throw m::error + { + http::BAD_GATEWAY, "M_REQUEST_TIMEOUT", "%s", e.what() + }; +} ircd::resource::method & ircd::resource::operator[](const string_view &name)