mirror of
https://gitlab.com/veilid/veilid.git
synced 2025-08-03 04:06:11 -04:00
Upgrade to Rust 1.86.0
This commit is contained in:
parent
452e4d0ab8
commit
13d5ca65d6
8 changed files with 502 additions and 437 deletions
511
Cargo.lock
generated
511
Cargo.lock
generated
File diff suppressed because it is too large
Load diff
|
@ -14,7 +14,7 @@ repository = "https://gitlab.com/veilid/veilid"
|
|||
authors = ["Veilid Team <contact@veilid.com>"]
|
||||
license = "MPL-2.0"
|
||||
edition = "2021"
|
||||
rust-version = "1.81.0"
|
||||
rust-version = "1.86.0"
|
||||
|
||||
[patch.crates-io]
|
||||
cursive = { git = "https://gitlab.com/veilid/cursive.git" }
|
||||
|
|
|
@ -18,7 +18,7 @@ ENV ZIG_VERSION=0.13.0
|
|||
ENV CMAKE_VERSION_MINOR=3.30
|
||||
ENV CMAKE_VERSION_PATCH=3.30.1
|
||||
ENV WASM_BINDGEN_CLI_VERSION=0.2.100
|
||||
ENV RUST_VERSION=1.81.0
|
||||
ENV RUST_VERSION=1.86.0
|
||||
ENV RUSTUP_HOME=/usr/local/rustup
|
||||
ENV RUSTUP_DIST_SERVER=https://static.rust-lang.org
|
||||
ENV CARGO_HOME=/usr/local/cargo
|
||||
|
|
|
@ -198,7 +198,7 @@ impl IGDManager {
|
|||
|
||||
// Map any port
|
||||
let desc = this.get_description(protocol_type, local_port);
|
||||
let mapped_port = match gw.add_any_port(convert_protocol_type(protocol_type), SocketAddr::new(local_ip, local_port), (UPNP_MAPPING_LIFETIME_MS + 999) / 1000, &desc) {
|
||||
let mapped_port = match gw.add_any_port(convert_protocol_type(protocol_type), SocketAddr::new(local_ip, local_port), UPNP_MAPPING_LIFETIME_MS.div_ceil(1000), &desc) {
|
||||
Ok(mapped_port) => mapped_port,
|
||||
Err(e) => {
|
||||
// Failed to map external port
|
||||
|
@ -295,7 +295,7 @@ impl IGDManager {
|
|||
match gw.add_any_port(
|
||||
convert_protocol_type(k.protocol_type),
|
||||
SocketAddr::new(local_ip, k.local_port),
|
||||
(UPNP_MAPPING_LIFETIME_MS + 999) / 1000,
|
||||
UPNP_MAPPING_LIFETIME_MS.div_ceil(1000),
|
||||
&desc,
|
||||
) {
|
||||
Ok(mapped_port) => {
|
||||
|
@ -343,7 +343,7 @@ impl IGDManager {
|
|||
convert_protocol_type(k.protocol_type),
|
||||
v.mapped_port,
|
||||
SocketAddr::new(local_ip, k.local_port),
|
||||
(UPNP_MAPPING_LIFETIME_MS + 999) / 1000,
|
||||
UPNP_MAPPING_LIFETIME_MS.div_ceil(1000),
|
||||
&desc,
|
||||
) {
|
||||
Ok(()) => {
|
||||
|
|
|
@ -124,8 +124,8 @@ pub struct IpcIncoming<'a> {
|
|||
impl Stream for IpcIncoming<'_> {
|
||||
type Item = io::Result<IpcStream>;
|
||||
|
||||
fn poll_next<'a>(
|
||||
mut self: std::pin::Pin<&'a mut Self>,
|
||||
fn poll_next(
|
||||
mut self: std::pin::Pin<&mut Self>,
|
||||
cx: &mut std::task::Context<'_>,
|
||||
) -> std::task::Poll<Option<Self::Item>> {
|
||||
if self.unord.is_empty() {
|
||||
|
|
|
@ -87,7 +87,7 @@ impl PlatformSupportWindows {
|
|||
for (n, netmask_elt) in netmask
|
||||
.iter_mut()
|
||||
.enumerate()
|
||||
.take((prefix.PrefixLength as usize + 7) / 8)
|
||||
.take((prefix.PrefixLength as usize).div_ceil(8))
|
||||
{
|
||||
let x_byte = ipv4_addr.octets()[n];
|
||||
let y_byte = a.octets()[n];
|
||||
|
@ -140,7 +140,7 @@ impl PlatformSupportWindows {
|
|||
for (n, netmask_elt) in netmask
|
||||
.iter_mut()
|
||||
.enumerate()
|
||||
.take((prefix.PrefixLength as usize + 15) / 16)
|
||||
.take((prefix.PrefixLength as usize).div_ceil(16))
|
||||
{
|
||||
let x_word = ipv6_addr.segments()[n];
|
||||
let y_word = a.segments()[n];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue