Tweaks
This commit is contained in:
@@ -42,7 +42,9 @@ pub fn main() {
|
|||||||
.status(status::OK)
|
.status(status::OK)
|
||||||
.body(()).unwrap();
|
.body(()).unwrap();
|
||||||
|
|
||||||
stream.send_response(response, true).unwrap();
|
if let Err(e) = stream.send_response(response, true) {
|
||||||
|
println!(" error responding; err={:?}", e);
|
||||||
|
}
|
||||||
|
|
||||||
Ok(())
|
Ok(())
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -94,6 +94,7 @@ impl<T, P, B> Connection<T, P, B>
|
|||||||
pub fn poll(&mut self) -> Poll<(), ConnectionError> {
|
pub fn poll(&mut self) -> Poll<(), ConnectionError> {
|
||||||
match self.poll2() {
|
match self.poll2() {
|
||||||
Err(e) => {
|
Err(e) => {
|
||||||
|
debug!("Connection::poll; err={:?}", e);
|
||||||
self.streams.recv_err(&e);
|
self.streams.recv_err(&e);
|
||||||
Err(e)
|
Err(e)
|
||||||
}
|
}
|
||||||
@@ -143,18 +144,13 @@ impl<T, P, B> Connection<T, P, B>
|
|||||||
// TODO: ACK must be sent THEN settings applied.
|
// TODO: ACK must be sent THEN settings applied.
|
||||||
}
|
}
|
||||||
Some(Ping(frame)) => {
|
Some(Ping(frame)) => {
|
||||||
unimplemented!();
|
|
||||||
/*
|
|
||||||
trace!("recv PING; frame={:?}", frame);
|
trace!("recv PING; frame={:?}", frame);
|
||||||
self.ping_pong.recv_ping(frame);
|
self.ping_pong.recv_ping(frame);
|
||||||
*/
|
|
||||||
}
|
}
|
||||||
Some(WindowUpdate(frame)) => {
|
Some(WindowUpdate(frame)) => {
|
||||||
unimplemented!();
|
|
||||||
/*
|
|
||||||
trace!("recv WINDOW_UPDATE; frame={:?}", frame);
|
trace!("recv WINDOW_UPDATE; frame={:?}", frame);
|
||||||
try!(self.streams.recv_window_update(frame));
|
// TODO: implement
|
||||||
*/
|
// try!(self.streams.recv_window_update(frame));
|
||||||
}
|
}
|
||||||
None => {
|
None => {
|
||||||
// TODO: Is this correct?
|
// TODO: Is this correct?
|
||||||
|
|||||||
@@ -95,8 +95,13 @@ impl<T> FramedRead<T> {
|
|||||||
Kind::PushPromise => {
|
Kind::PushPromise => {
|
||||||
frame::PushPromise::load(head, &bytes[frame::HEADER_LEN..])?.into()
|
frame::PushPromise::load(head, &bytes[frame::HEADER_LEN..])?.into()
|
||||||
}
|
}
|
||||||
Kind::Priority |
|
Kind::Priority => {
|
||||||
Kind::Continuation |
|
// TODO: implement
|
||||||
|
return Ok(None);
|
||||||
|
}
|
||||||
|
Kind::Continuation => {
|
||||||
|
unimplemented!();
|
||||||
|
}
|
||||||
Kind::Unknown => {
|
Kind::Unknown => {
|
||||||
unimplemented!()
|
unimplemented!()
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user