Skip to content

Commit

Permalink
apps: use H3_NO_ERROR in HTTP/3 clients
Browse files Browse the repository at this point in the history
  • Loading branch information
LPardue authored and ghedo committed Apr 20, 2023
1 parent 36b76af commit 0b37da1
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions apps/src/common.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1288,7 +1288,7 @@ impl HttpConn for Http3Conn {
);
}

match conn.close(true, 0x00, b"kthxbye") {
match conn.close(true, 0x100, b"kthxbye") {
// Already closed.
Ok(_) | Err(quiche::Error::Done) => (),

Expand All @@ -1302,7 +1302,7 @@ impl HttpConn for Http3Conn {
Ok((_stream_id, quiche::h3::Event::Reset(e))) => {
error!("request was reset by peer with {}, closing...", e);

match conn.close(true, 0x00, b"kthxbye") {
match conn.close(true, 0x100, b"kthxbye") {
// Already closed.
Ok(_) | Err(quiche::Error::Done) => (),

Expand Down
4 changes: 2 additions & 2 deletions quiche/examples/http3-client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,7 @@ fn main() {
req_start.elapsed()
);

conn.close(true, 0x00, b"kthxbye").unwrap();
conn.close(true, 0x100, b"kthxbye").unwrap();
},

Ok((_stream_id, quiche::h3::Event::Reset(e))) => {
Expand All @@ -277,7 +277,7 @@ fn main() {
e
);

conn.close(true, 0x00, b"kthxbye").unwrap();
conn.close(true, 0x100, b"kthxbye").unwrap();
},

Ok((_flow_id, quiche::h3::Event::Datagram)) => (),
Expand Down
4 changes: 2 additions & 2 deletions tools/http3_test/src/runner.rs
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,7 @@ pub fn run(
req_start.elapsed()
);

match conn.close(true, 0x00, b"kthxbye") {
match conn.close(true, 0x100, b"kthxbye") {
// Already closed.
Ok(_) | Err(quiche::Error::Done) => (),

Expand Down Expand Up @@ -343,7 +343,7 @@ pub fn run(
req_start.elapsed()
);

match conn.close(true, 0x00, b"kthxbye") {
match conn.close(true, 0x100, b"kthxbye") {
// Already closed.
Ok(_) | Err(quiche::Error::Done) => (),

Expand Down

0 comments on commit 0b37da1

Please sign in to comment.