1
0
Fork 0
mirror of https://github.com/actix/actix-web.git synced 2025-04-08 02:49:52 +00:00

Log decoder errors

This commit is contained in:
Maciej Hirsz 2019-11-05 15:31:12 +01:00
parent f0612f7570
commit 1be9ecf668

View file

@ -558,11 +558,13 @@ where
}
Ok(None) => break,
Err(ParseError::Io(e)) => {
error!("IO error when parsing!");
self.client_disconnected();
self.error = Some(DispatchError::Io(e));
break;
}
Err(e) => {
error!("Parsing error {:?}", e);
if let Some(mut payload) = self.payload.take() {
payload.set_error(PayloadError::EncodingCorrupted);
}