Skip to content

Commit

Permalink
Upgrade socket2 to 0.5
Browse files Browse the repository at this point in the history
  • Loading branch information
djc committed May 9, 2023
1 parent 37e7b74 commit 1e39c8d
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion perf/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ rustls = { version = "0.21.0", default-features = false, features = ["dangerous_
rustls-pemfile = "1.0.0"
serde = { version = "1.0", features = ["derive"], optional = true }
serde_json = { version = "1.0", optional = true }
socket2 = "0.4"
socket2 = "0.5"
webpki = "0.22"
clap = { version = "3.2", features = ["derive"] }
tokio = { version = "1.0.1", features = ["rt", "macros", "signal", "net", "sync"] }
Expand Down
2 changes: 1 addition & 1 deletion quinn-udp/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ maintenance = { status = "experimental" }

[dependencies]
libc = "0.2.113"
socket2 = "0.4" # 0.5.1 has an MSRV of 1.63
socket2 = "0.5"
tracing = "0.1.10"

[target.'cfg(windows)'.dependencies]
Expand Down
8 changes: 4 additions & 4 deletions quinn-udp/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
#![warn(clippy::use_self)]

#[cfg(unix)]
use std::os::unix::io::AsRawFd;
use std::os::unix::io::AsFd;
#[cfg(windows)]
use std::os::windows::io::AsRawSocket;
use std::os::windows::io::AsSocket;
#[cfg(not(windows))]
use std::sync::atomic::AtomicBool;
use std::{
Expand Down Expand Up @@ -178,7 +178,7 @@ pub struct UdpSockRef<'a>(socket2::SockRef<'a>);
#[cfg(unix)]
impl<'s, S> From<&'s S> for UdpSockRef<'s>
where
S: AsRawFd,
S: AsFd,
{
fn from(socket: &'s S) -> Self {
Self(socket.into())
Expand All @@ -188,7 +188,7 @@ where
#[cfg(windows)]
impl<'s, S> From<&'s S> for UdpSockRef<'s>
where
S: AsRawSocket,
S: AsSocket,
{
fn from(socket: &'s S) -> Self {
Self(socket.into())
Expand Down

0 comments on commit 1e39c8d

Please sign in to comment.