1
0
mirror of https://github.com/fafhrd91/actix-web synced 2025-08-30 08:38:16 +02:00

Fix server websockets big payloads support

This commit is contained in:
Nikolay Kim
2018-03-19 17:27:03 -07:00
parent 35ee5d36d8
commit 6cd40df387
8 changed files with 178 additions and 154 deletions

View File

@@ -329,7 +329,8 @@ impl<S> Stream for WsStream<S> where S: Stream<Item=Bytes, Error=PayloadError> {
match String::from_utf8(tmp) {
Ok(s) =>
Ok(Async::Ready(Some(Message::Text(s)))),
Err(_) => {
Err(e) => {
println!("ENC: {:?}", e);
self.closed = true;
Err(ProtocolError::BadEncoding)
}