Skip to content

Commit

Permalink
Fix warning
Browse files Browse the repository at this point in the history
  • Loading branch information
elliottt committed Jun 26, 2024
1 parent 73bdb32 commit 7a8e4f3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/src/component/http_resp.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ use {
cfg_if::cfg_if,
http::{HeaderName, HeaderValue},
hyper::http::response::Response,
std::str::FromStr,
};

const MAX_HEADER_NAME_LEN: usize = (1 << 16) - 1;
Expand Down Expand Up @@ -137,6 +136,7 @@ impl http_resp::Host for Session {
let _ = (h, name, max_len, cursor);
return Err(Error::FatalError("A fatal error occurred in the test-only implementation of header_values_get".to_string()).into());
} else {
use std::str::FromStr;
if name.len() > MAX_HEADER_NAME_LEN {
return Err(Error::InvalidArgument.into());
}
Expand Down

0 comments on commit 7a8e4f3

Please sign in to comment.