From e1c32ec015939588062323f7c068bd76e370470d Mon Sep 17 00:00:00 2001 From: Ronald Chan Date: Mon, 9 Sep 2019 15:19:11 +0800 Subject: [PATCH] fix h2 not using error response --- actix-http/src/h2/dispatcher.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/actix-http/src/h2/dispatcher.rs b/actix-http/src/h2/dispatcher.rs index 69c620e62..888f9065e 100644 --- a/actix-http/src/h2/dispatcher.rs +++ b/actix-http/src/h2/dispatcher.rs @@ -257,8 +257,8 @@ where } } Ok(Async::NotReady) => Ok(Async::NotReady), - Err(_e) => { - let res: Response = Response::InternalServerError().finish(); + Err(e) => { + let res: Response = e.into().into(); let (res, body) = res.replace_body(()); let mut send = send.take().unwrap();