Catch exceptions in websockets and drop the connection

pull/88/head
Oliver Giles 5 years ago
parent c0556b871b
commit 31c64980f7

@ -259,6 +259,11 @@ private:
}
// unhandled/unknown message
return lc.ws->disconnect();
}, [](kj::Exception&& e){
// server logs suggest early catching here avoids fatal exception later
// TODO: reproduce in unit test
KJ_LOG(WARNING, e.getDescription());
return kj::READY_NOW;
});
}

Loading…
Cancel
Save