This commit is contained in:
Carl Lerche
2017-08-09 11:43:55 -07:00
parent f39e983af0
commit 0bf0e79132
3 changed files with 13 additions and 10 deletions

View File

@@ -42,7 +42,9 @@ pub fn main() {
.status(status::OK)
.body(()).unwrap();
stream.send_response(response, true).unwrap();
if let Err(e) = stream.send_response(response, true) {
println!(" error responding; err={:?}", e);
}
Ok(())
})

View File

@@ -94,6 +94,7 @@ impl<T, P, B> Connection<T, P, B>
pub fn poll(&mut self) -> Poll<(), ConnectionError> {
match self.poll2() {
Err(e) => {
debug!("Connection::poll; err={:?}", e);
self.streams.recv_err(&e);
Err(e)
}
@@ -143,18 +144,13 @@ impl<T, P, B> Connection<T, P, B>
// TODO: ACK must be sent THEN settings applied.
}
Some(Ping(frame)) => {
unimplemented!();
/*
trace!("recv PING; frame={:?}", frame);
self.ping_pong.recv_ping(frame);
*/
}
Some(WindowUpdate(frame)) => {
unimplemented!();
/*
trace!("recv WINDOW_UPDATE; frame={:?}", frame);
try!(self.streams.recv_window_update(frame));
*/
// TODO: implement
// try!(self.streams.recv_window_update(frame));
}
None => {
// TODO: Is this correct?

View File

@@ -95,8 +95,13 @@ impl<T> FramedRead<T> {
Kind::PushPromise => {
frame::PushPromise::load(head, &bytes[frame::HEADER_LEN..])?.into()
}
Kind::Priority |
Kind::Continuation |
Kind::Priority => {
// TODO: implement
return Ok(None);
}
Kind::Continuation => {
unimplemented!();
}
Kind::Unknown => {
unimplemented!()
}