Skip to content

Commit

Permalink
chore: bump MSRV to 1.76
Browse files Browse the repository at this point in the history
  • Loading branch information
fujiapple852 committed Sep 30, 2024
1 parent b54bb91 commit c20e334
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ repository = "https://github.com/fujiapple852/trippy"
readme = "README.md"
license = "Apache-2.0"
edition = "2021"
rust-version = "1.75"
rust-version = "1.76"
keywords = ["cli", "tui", "traceroute", "ping", "icmp"]
categories = ["command-line-utilities", "network-programming"]

Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM rust:1.75 as build-env
FROM rust:1.76 as build-env
RUN rustup target add x86_64-unknown-linux-musl
WORKDIR /app
COPY Cargo.toml /app
Expand Down
4 changes: 3 additions & 1 deletion crates/trippy-core/src/net/platform/unix.rs
Original file line number Diff line number Diff line change
Expand Up @@ -533,7 +533,9 @@ mod socket {
// bytes to the `buf`fer, so this casting is safe.
#![allow(unsafe_code)]
fn recv_from_into_buf(&self, buf: &mut [u8]) -> io::Result<(usize, Option<SocketAddr>)> {
let buf = unsafe { &mut *(buf as *mut [u8] as *mut [std::mem::MaybeUninit<u8>]) };
let buf = unsafe {
&mut *(std::ptr::from_mut::<[u8]>(buf) as *mut [std::mem::MaybeUninit<u8>])
};
self.recv_from(buf)
.map(|(size, addr)| (size, addr.as_socket()))
}
Expand Down
2 changes: 1 addition & 1 deletion examples/hello-world/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name = "hello-world"
version = "0.1.0"
license = "Apache-2.0"
edition = "2021"
rust-version = "1.75"
rust-version = "1.76"
publish = false

[dependencies]
Expand Down
2 changes: 1 addition & 1 deletion examples/traceroute/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name = "traceroute"
version = "0.1.0"
license = "Apache-2.0"
edition = "2021"
rust-version = "1.75"
rust-version = "1.76"
publish = false

[dependencies]
Expand Down

0 comments on commit c20e334

Please sign in to comment.