Commit Graph

379 Commits

Author SHA1 Message Date
Josh Triplett 4de64c18de
Merge pull request #202 from forkgull/notgull/clippy
Please clippy
2023-10-08 13:06:00 +08:00
Josh Triplett e6953ac778
Merge pull request #201 from forkgull/no-async-std
Replace async-std with smol crates
2023-10-08 13:01:24 +08:00
John Nunley 4293cea79c Please clippy
Signed-off-by: John Nunley <dev@notgull.net>
2023-09-23 11:01:02 -07:00
John Nunley 235de5be5d
Alphabetize dependencies
This helps cargo-add work better

Signed-off-by: John Nunley <dev@notgull.net>
2023-09-20 20:29:36 -07:00
John Nunley 20bcc7da32
Use async-global-executor to spawn tasks
This is a placeholder until I figure out how to actually handle this
without the global executor.

Signed-off-by: John Nunley <dev@notgull.net>
2023-09-20 20:28:18 -07:00
John Nunley f1f0ffc628
Replace async-std with smol crates
It would be nice to be able to use this in environments where I use
smol. However this crate imports the async-std crate for I/O. This
commit partially replaces async-std with the equivalent combinators from
futures-lite and async-io, two smol crates that async-std depends on
anyways.

The task spawn is still left in, as replacing it will be controversial.

Signed-off-by: John Nunley <dev@notgull.net>
2023-09-20 20:20:15 -07:00
Josh Triplett 882fa23e7a async-h1 2.3.3 2021-11-21 07:02:30 -08:00
Josh Triplett 731a096860
Merge pull request #196 from joshtriplett/wip-fix-ff7
Rewrite `Transfer-Encoding: chunked` support to fix #195
2021-11-20 17:46:39 -08:00
Josh Triplett 51429f3d42 Rewrite `Transfer-Encoding: chunked` support to fix bug #195
This implementation no longer stops short when it encounters a chunk of
size 0xFF7.
2021-11-19 17:32:46 -08:00
Josh Triplett f8b679a9e4 Add test with a chunk just under the buffer size (currently fails)
Attempting to decode a chunk with length 0xFF7 (4087), exactly 9 bytes
less than the buffer size, causes the decoder to stop after that chunk.
2021-11-19 17:32:39 -08:00
Josh Triplett b19548e26e Fix clippy warnings so that CI passes again 2021-11-19 17:31:56 -08:00
Jacob Rothstein a1448c379b
(cargo-release) version 2.3.2 2021-03-03 14:02:29 -08:00
Jacob Rothstein dffae5fb49 don't panic if the connection is closed at any point 2021-03-03 13:59:50 -08:00
Jacob Rothstein 9993b0475f
(cargo-release) version 2.3.1 2021-02-04 15:07:30 -08:00
Diggory Blake 54d8b67988 Fix race condition in test-utils CloseableCursor implementation 2021-02-03 18:28:31 -08:00
Josh Triplett 4d8bb9762b Disable default-features on http-types
With the next http-types release, this will allow omitting the cookie
feature and associated dependencies.
2021-01-21 14:11:27 -08:00
Javier Viola 81687df9d6 Update src/server/mod.rs
Remove padding whitespace.
2021-01-21 14:10:45 -08:00
Javier Viola 5887b3eb6c Update src/server/mod.rs
Remove dup line.
2021-01-21 14:10:45 -08:00
mu2019 b119ab3c2e Update src/server/mod.rs
Co-authored-by: Javier Viola <pepoviola@gmail.com>
2021-01-21 14:10:45 -08:00
mu2019 14aff92c82 fix fmt error. 2021-01-21 14:10:45 -08:00
mu2019 273ed4595b fix firefox can't entablish websocket.
firefox send websocket upgrade header "Connection:keep-alive, Upgrade" can't match with connection_header_as_str.eq_ignore_ascii_case("upgrade")
2021-01-21 14:10:45 -08:00
Yoshua Wuyts b71e34682e
Merge pull request #166 from http-rs/400-on-content-len-chunked
400 on content len chunked
2020-12-18 16:33:06 +01:00
Yoshua Wuyts b22c7e68a8 fix clippy 2020-12-18 16:21:13 +01:00
Yoshua Wuyts 2ee67c14a9 Use structured ContentLength parser 2020-12-18 16:15:52 +01:00
Yoshua Wuyts 8682991596 return 400 when both content-len and chunked are passed 2020-12-18 16:12:29 +01:00
Jacob Rothstein b1651f3f78
(cargo-release) version 2.3.0 2020-12-17 16:57:24 -08:00
Jacob Rothstein 7df79f1d5d
keep-alive: always read body to end 2020-12-13 00:47:03 -08:00
Jacob Rothstein 69bed38fd7
no longer use async_std::sync::channel 2020-12-11 11:51:09 -08:00
Jacob Rothstein 7179b60595
(cargo-release) version 2.2.1 2020-12-05 11:51:16 -08:00
Jacob Rothstein f066c50509 no need to rename path
it's actually "path and query and fragment"  but "path" is a bit easier to read
2020-12-05 11:50:09 -08:00
Jacob Rothstein eecbc57ee4 fix server decode regression introduced in #153 2020-12-05 11:50:09 -08:00
vkill 919c05f71a Fix server url decode 2020-12-05 11:50:09 -08:00
Jacob Rothstein 005b94cb3c
(cargo-release) version 2.2.0 2020-12-04 13:37:58 -08:00
Jacob Rothstein 51385db693 update dependencies and use http-types 2.9.0 2020-12-04 13:36:14 -08:00
Jacob Rothstein c16f4c7334 use main 2020-12-04 13:36:14 -08:00
Jacob Rothstein 7ffae3546a improve readability 2020-12-04 13:36:14 -08:00
Jacob Rothstein 9769d09b66 build against the stabilization branch 2020-12-04 13:36:14 -08:00
Jacob Rothstein 2332234376 no longer depend on unstable 2020-12-04 13:36:14 -08:00
Jacob Rothstein 98ca945278 make sure we don't loop after an upgrade 2020-12-04 13:36:14 -08:00
Jacob Rothstein c563d64d0a add support for upgrades 2020-12-04 13:36:14 -08:00
Jacob Rothstein 66b887df9d move the Read impl higher, it's the most important thing 2020-11-28 14:39:00 -08:00
Jacob Rothstein 95385df32c small docs update and some code golf 2020-11-28 14:39:00 -08:00
Jacob Rothstein cdea35513d add a test for the critical function `max_bytes_to_read` 2020-11-28 14:39:00 -08:00
Jacob Rothstein f6a6528133 Incorporate feedback from review
Co-authored-by: Yoshua Wuyts <yoshuawuyts@gmail.com>
2020-11-28 14:39:00 -08:00
Jacob Rothstein ed6f181d98 remove accidental double-mut 2020-11-28 14:39:00 -08:00
Jacob Rothstein 356847b2f3 📎 thanks clippy 🖇 2020-11-28 14:39:00 -08:00
Jacob Rothstein 0678bedfc3 🤫 2020-11-28 14:39:00 -08:00
Jacob Rothstein 66c84273fd also use a guess of 128 bytes on the server 2020-11-28 14:39:00 -08:00
Jacob Rothstein 4b6cef5c74 use 128 bytes 2020-11-28 14:39:00 -08:00
Jacob Rothstein 32b8bea131 new encoder for both client and server 2020-11-28 14:39:00 -08:00