[INFO] fetching crate async-dnssd 0.5.1... [INFO] checking async-dnssd-0.5.1 against try#ccf408f4326a858c00dd845a64a86b16f360a801 for pr-129466-2 [INFO] extracting crate async-dnssd 0.5.1 into /workspace/builds/worker-3-tc2/source [INFO] validating manifest of crates.io crate async-dnssd 0.5.1 on toolchain ccf408f4326a858c00dd845a64a86b16f360a801 [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+ccf408f4326a858c00dd845a64a86b16f360a801" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] started tweaking crates.io crate async-dnssd 0.5.1 [INFO] removed 0 missing examples [INFO] finished tweaking crates.io crate async-dnssd 0.5.1 [INFO] tweaked toml for crates.io crate async-dnssd 0.5.1 written to /workspace/builds/worker-3-tc2/source/Cargo.toml [INFO] crate crates.io crate async-dnssd 0.5.1 already has a lockfile, it will not be regenerated [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+ccf408f4326a858c00dd845a64a86b16f360a801" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-3-tc2/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-3-tc2/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:ceb6ea022f8a89cebbe621bb4987e73a935bd40dfbb726f832cfff4742a5b95a" "/opt/rustwide/cargo-home/bin/cargo" "+ccf408f4326a858c00dd845a64a86b16f360a801" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] d8bf5f0e7738b005a4c7751ebf158fdac0859eddd3462a3497696511ffe89197 [INFO] running `Command { std: "docker" "start" "-a" "d8bf5f0e7738b005a4c7751ebf158fdac0859eddd3462a3497696511ffe89197", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "d8bf5f0e7738b005a4c7751ebf158fdac0859eddd3462a3497696511ffe89197", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "d8bf5f0e7738b005a4c7751ebf158fdac0859eddd3462a3497696511ffe89197", kill_on_drop: false }` [INFO] [stdout] d8bf5f0e7738b005a4c7751ebf158fdac0859eddd3462a3497696511ffe89197 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-3-tc2/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-3-tc2/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_INCREMENTAL=0" "-e" "RUST_BACKTRACE=full" "-e" "RUSTFLAGS=--cap-lints=forbid" "-e" "RUSTDOCFLAGS=--cap-lints=forbid" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:ceb6ea022f8a89cebbe621bb4987e73a935bd40dfbb726f832cfff4742a5b95a" "/opt/rustwide/cargo-home/bin/cargo" "+ccf408f4326a858c00dd845a64a86b16f360a801" "check" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] d44565cd572c677838ced8c36b2b69b07898c7ac7a637b627a2b70307e01e2a0 [INFO] running `Command { std: "docker" "start" "-a" "d44565cd572c677838ced8c36b2b69b07898c7ac7a637b627a2b70307e01e2a0", kill_on_drop: false }` [INFO] [stderr] Copying to /tmp/fixit [INFO] [stderr] Running `cargo fix --edition` [INFO] [stderr] Migrating Cargo.toml from 2021 edition to 2024 [INFO] [stderr] Compiling proc-macro2 v1.0.34 [INFO] [stderr] Compiling unicode-xid v0.2.2 [INFO] [stderr] Compiling syn v1.0.82 [INFO] [stderr] Compiling futures-core v0.3.19 [INFO] [stderr] Compiling futures-channel v0.3.19 [INFO] [stderr] Compiling memchr v2.4.1 [INFO] [stderr] Compiling futures-task v0.3.19 [INFO] [stderr] Compiling futures-util v0.3.19 [INFO] [stderr] Checking pin-project-lite v0.2.7 [INFO] [stderr] Compiling libc v0.2.112 [INFO] [stderr] Checking futures-sink v0.3.19 [INFO] [stderr] Compiling log v0.4.14 [INFO] [stderr] Checking slab v0.4.5 [INFO] [stderr] Checking futures-io v0.3.19 [INFO] [stderr] Compiling pkg-config v0.3.24 [INFO] [stderr] Compiling async-dnssd v0.5.1 (/tmp/fixit) [INFO] [stderr] Migrating build.rs from 2021 edition to 2024 [INFO] [stderr] Compiling quote v1.0.10 [INFO] [stderr] Checking mio v0.7.14 [INFO] [stderr] Compiling futures-macro v0.3.19 [INFO] [stderr] Compiling tokio-macros v1.7.0 [INFO] [stderr] Checking tokio v1.15.0 [INFO] [stderr] Checking futures-executor v0.3.19 [INFO] [stderr] Migrating src/lib.rs from 2021 edition to 2024 [INFO] [stderr] Checking futures v0.3.19 [INFO] [stderr] warning: failed to automatically apply fixes suggested by rustc to crate `async_dnssd` [INFO] [stderr] [INFO] [stderr] after fixes were automatically applied the compiler reported errors within these files: [INFO] [stderr] [INFO] [stderr] * src/ffi.rs [INFO] [stderr] [INFO] [stderr] This likely indicates a bug in either rustc or cargo itself, [INFO] [stderr] and we would appreciate a bug report! You're likely to see [INFO] [stderr] a number of compiler warnings after this message which cargo [INFO] [stderr] attempted to fix but failed. If you could open an issue at [INFO] [stderr] https://github.com/rust-lang/rust/issues [INFO] [stderr] quoting the full output of this command we'd be very appreciative! [INFO] [stderr] Note that you may be able to make some more progress in the near-term [INFO] [stderr] fixing code with the `--broken-code` flag [INFO] [stderr] [INFO] [stderr] The following errors were reported: [INFO] [stderr] error[E0658]: fragment specifier `expr_2021` is unstable [INFO] [stderr] --> src/ffi.rs:48:58 [INFO] [stderr] | [INFO] [stderr] 48 | ($(#[$m:meta])* $name:ident : $ty:tt => $($case:ident = $val:expr_2021,)* ) => ( [INFO] [stderr] | ^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: see issue #123742 for more information [INFO] [stderr] = help: add `#![feature(expr_fragment_specifier_2024)]` to the crate attributes to enable [INFO] [stderr] = note: this compiler was built on 2024-09-17; consider upgrading it if it is out of date [INFO] [stderr] [INFO] [stderr] error: aborting due to 1 previous error [INFO] [stderr] [INFO] [stderr] For more information about this error, try `rustc --explain E0658`. [INFO] [stderr] Original diagnostics will follow. [INFO] [stderr] [INFO] [stdout] warning: the `expr` fragment specifier will accept more expressions in the 2024 edition [INFO] [stdout] --> src/ffi.rs:48:63 [INFO] [stdout] | [INFO] [stdout] 48 | ($(#[$m:meta])* $name:ident : $ty:tt => $($case:ident = $val:expr,)* ) => ( [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = warning: this changes meaning in Rust 2024 [INFO] [stdout] = note: for more information, see Migration Guide [INFO] [stdout] = note: `--force-warn edition-2024-expr-fragment-specifier` implied by `--force-warn rust-2024-compatibility` [INFO] [stdout] help: to keep the existing behavior, use the `expr_2021` fragment specifier [INFO] [stdout] | [INFO] [stdout] 48 | ($(#[$m:meta])* $name:ident : $ty:tt => $($case:ident = $val:expr_2021,)* ) => ( [INFO] [stdout] | ~~~~~~~~~ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: extern blocks should be unsafe [INFO] [stdout] --> src/ffi.rs:184:1 [INFO] [stdout] | [INFO] [stdout] 184 | extern "C" { [INFO] [stdout] | ^ [INFO] [stdout] | | [INFO] [stdout] | _help: needs `unsafe` before the extern keyword: `unsafe` [INFO] [stdout] | | [INFO] [stdout] 185 | | pub fn DNSServiceRefSockFD(sd_ref: DNSServiceRef) -> c_int; [INFO] [stdout] 186 | | pub fn DNSServiceProcessResult(sd_ref: DNSServiceRef) -> DNSServiceErrorType; [INFO] [stdout] 187 | | pub fn DNSServiceRefDeallocate(sd_ref: DNSServiceRef); [INFO] [stdout] ... | [INFO] [stdout] 289 | | ) -> c_int; [INFO] [stdout] 290 | | } [INFO] [stdout] | |_^ [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024! [INFO] [stdout] = note: for more information, see issue #123743 [INFO] [stdout] = note: `--force-warn missing-unsafe-on-extern` implied by `--force-warn rust-2024-compatibility` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `std::ffi::CStr::from_ptr` is unsafe and requires unsafe block [INFO] [stdout] --> src/cstr.rs:10:2 [INFO] [stdout] | [INFO] [stdout] 10 | ffi::CStr::from_ptr(s) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/cstr.rs:9:1 [INFO] [stdout] | [INFO] [stdout] 9 | pub unsafe fn from_cstr(s: *const c_char) -> io::Result<&'static str> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] = note: `--force-warn unsafe-op-in-unsafe-fn` implied by `--force-warn rust-2024-compatibility` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: dereference of raw pointer is unsafe and requires unsafe block [INFO] [stdout] --> src/future.rs:46:46 [INFO] [stdout] | [INFO] [stdout] 46 | let sender: &mut CallbackContext = &mut *sender; [INFO] [stdout] | ^^^^^^^ dereference of raw pointer [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/future.rs:37:2 [INFO] [stdout] | [INFO] [stdout] 37 | / pub(crate) unsafe fn run_callback( [INFO] [stdout] 38 | | context: *mut c_void, [INFO] [stdout] 39 | | error_code: ffi::DNSServiceErrorType, [INFO] [stdout] 40 | | f: F, [INFO] [stdout] 41 | | ) where [INFO] [stdout] 42 | | F: FnOnce() -> io::Result, [INFO] [stdout] 43 | | T: ::std::fmt::Debug, [INFO] [stdout] | |_____________________________^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `stream::ServiceStream::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/browse.rs:104:2 [INFO] [stdout] | [INFO] [stdout] 104 | / CallbackStream::run_callback(context, error_code, || { [INFO] [stdout] 105 | | let service_name = cstr::from_cstr(service_name)?; [INFO] [stdout] 106 | | let reg_type = cstr::from_cstr(reg_type)?; [INFO] [stdout] 107 | | let reply_domain = cstr::from_cstr(reply_domain)?; [INFO] [stdout] ... | [INFO] [stdout] 115 | | }) [INFO] [stdout] 116 | | }); [INFO] [stdout] | |______^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/browse.rs:94:1 [INFO] [stdout] | [INFO] [stdout] 94 | / unsafe extern "C" fn browse_callback( [INFO] [stdout] 95 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 96 | | flags: ffi::DNSServiceFlags, [INFO] [stdout] 97 | | interface_index: u32, [INFO] [stdout] ... | [INFO] [stdout] 102 | | context: *mut c_void, [INFO] [stdout] 103 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/browse.rs:105:22 [INFO] [stdout] | [INFO] [stdout] 105 | let service_name = cstr::from_cstr(service_name)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/browse.rs:106:18 [INFO] [stdout] | [INFO] [stdout] 106 | let reg_type = cstr::from_cstr(reg_type)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/browse.rs:107:22 [INFO] [stdout] | [INFO] [stdout] 107 | let reply_domain = cstr::from_cstr(reply_domain)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `future::ServiceFuture::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/connection.rs:93:2 [INFO] [stdout] | [INFO] [stdout] 93 | CallbackFuture::run_callback(context, error_code, || Ok(RegisterRecordResult)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/connection.rs:86:1 [INFO] [stdout] | [INFO] [stdout] 86 | / unsafe extern "C" fn register_record_callback( [INFO] [stdout] 87 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 88 | | _record_ref: ffi::DNSRecordRef, [INFO] [stdout] 89 | | _flags: ffi::DNSServiceFlags, [INFO] [stdout] 90 | | error_code: ffi::DNSServiceErrorType, [INFO] [stdout] 91 | | context: *mut c_void, [INFO] [stdout] 92 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `stream::ServiceStream::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/enumerate_domains.rs:104:2 [INFO] [stdout] | [INFO] [stdout] 104 | / CallbackStream::run_callback(context, error_code, || { [INFO] [stdout] 105 | | let reply_domain = cstr::from_cstr(reply_domain)?; [INFO] [stdout] 106 | | [INFO] [stdout] 107 | | Ok(EnumerateResult { [INFO] [stdout] ... | [INFO] [stdout] 111 | | }) [INFO] [stdout] 112 | | }); [INFO] [stdout] | |______^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/enumerate_domains.rs:96:1 [INFO] [stdout] | [INFO] [stdout] 96 | / unsafe extern "C" fn enumerate_callback( [INFO] [stdout] 97 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 98 | | flags: ffi::DNSServiceFlags, [INFO] [stdout] 99 | | interface_index: u32, [INFO] [stdout] ... | [INFO] [stdout] 102 | | context: *mut c_void, [INFO] [stdout] 103 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/enumerate_domains.rs:105:22 [INFO] [stdout] | [INFO] [stdout] 105 | let reply_domain = cstr::from_cstr(reply_domain)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `stream::ServiceStream::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/query_record.rs:108:2 [INFO] [stdout] | [INFO] [stdout] 108 | / CallbackStream::run_callback(context, error_code, || { [INFO] [stdout] 109 | | let fullname = cstr::from_cstr(fullname)?; [INFO] [stdout] 110 | | let rdata = ::std::slice::from_raw_parts(rdata, rd_len as usize); [INFO] [stdout] ... | [INFO] [stdout] 120 | | }) [INFO] [stdout] 121 | | }); [INFO] [stdout] | |______^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/query_record.rs:95:1 [INFO] [stdout] | [INFO] [stdout] 95 | / unsafe extern "C" fn query_record_callback( [INFO] [stdout] 96 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 97 | | flags: ffi::DNSServiceFlags, [INFO] [stdout] 98 | | interface_index: u32, [INFO] [stdout] ... | [INFO] [stdout] 106 | | context: *mut c_void, [INFO] [stdout] 107 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/query_record.rs:109:18 [INFO] [stdout] | [INFO] [stdout] 109 | let fullname = cstr::from_cstr(fullname)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `std::slice::from_raw_parts` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/query_record.rs:110:15 [INFO] [stdout] | [INFO] [stdout] 110 | let rdata = ::std::slice::from_raw_parts(rdata, rd_len as usize); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `future::ServiceFuture::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/register.rs:149:2 [INFO] [stdout] | [INFO] [stdout] 149 | / CallbackFuture::run_callback(context, error_code, || { [INFO] [stdout] 150 | | let name = cstr::from_cstr(name)?; [INFO] [stdout] 151 | | let reg_type = cstr::from_cstr(reg_type)?; [INFO] [stdout] 152 | | let domain = cstr::from_cstr(domain)?; [INFO] [stdout] ... | [INFO] [stdout] 158 | | }) [INFO] [stdout] 159 | | }); [INFO] [stdout] | |______^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/register.rs:140:1 [INFO] [stdout] | [INFO] [stdout] 140 | / unsafe extern "C" fn register_callback( [INFO] [stdout] 141 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 142 | | _flags: ffi::DNSServiceFlags, [INFO] [stdout] 143 | | error_code: ffi::DNSServiceErrorType, [INFO] [stdout] ... | [INFO] [stdout] 147 | | context: *mut c_void, [INFO] [stdout] 148 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/register.rs:150:14 [INFO] [stdout] | [INFO] [stdout] 150 | let name = cstr::from_cstr(name)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/register.rs:151:18 [INFO] [stdout] | [INFO] [stdout] 151 | let reg_type = cstr::from_cstr(reg_type)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/register.rs:152:16 [INFO] [stdout] | [INFO] [stdout] 152 | let domain = cstr::from_cstr(domain)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `stream::ServiceStream::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/resolve.rs:100:2 [INFO] [stdout] | [INFO] [stdout] 100 | / CallbackStream::run_callback(context, error_code, || { [INFO] [stdout] 101 | | let fullname = cstr::from_cstr(fullname)?; [INFO] [stdout] 102 | | let host_target = cstr::from_cstr(host_target)?; [INFO] [stdout] 103 | | let txt = ::std::slice::from_raw_parts(txt_record, txt_len as usize); [INFO] [stdout] ... | [INFO] [stdout] 112 | | }) [INFO] [stdout] 113 | | }); [INFO] [stdout] | |______^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/resolve.rs:88:1 [INFO] [stdout] | [INFO] [stdout] 88 | / unsafe extern "C" fn resolve_callback( [INFO] [stdout] 89 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 90 | | flags: ffi::DNSServiceFlags, [INFO] [stdout] 91 | | interface_index: u32, [INFO] [stdout] ... | [INFO] [stdout] 98 | | context: *mut c_void, [INFO] [stdout] 99 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/resolve.rs:101:18 [INFO] [stdout] | [INFO] [stdout] 101 | let fullname = cstr::from_cstr(fullname)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/resolve.rs:102:21 [INFO] [stdout] | [INFO] [stdout] 102 | let host_target = cstr::from_cstr(host_target)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `std::slice::from_raw_parts` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/resolve.rs:103:13 [INFO] [stdout] | [INFO] [stdout] 103 | let txt = ::std::slice::from_raw_parts(txt_record, txt_len as usize); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: dereference of raw pointer is unsafe and requires unsafe block [INFO] [stdout] --> src/stream.rs:43:46 [INFO] [stdout] | [INFO] [stdout] 43 | let sender: &mut CallbackContext = &mut *sender; [INFO] [stdout] | ^^^^^^^ dereference of raw pointer [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/stream.rs:34:2 [INFO] [stdout] | [INFO] [stdout] 34 | / pub(crate) unsafe fn run_callback( [INFO] [stdout] 35 | | context: *mut c_void, [INFO] [stdout] 36 | | error_code: ffi::DNSServiceErrorType, [INFO] [stdout] 37 | | f: F, [INFO] [stdout] 38 | | ) where [INFO] [stdout] 39 | | F: FnOnce() -> io::Result, [INFO] [stdout] 40 | | T: ::std::fmt::Debug, [INFO] [stdout] | |_____________________________^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: call to deprecated safe function `std::env::set_var` is unsafe and requires unsafe block [INFO] [stdout] --> src/lib.rs:129:5 [INFO] [stdout] | [INFO] [stdout] 129 | std::env::set_var(AVAHI_COMPAT_NOWARN, "1"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024! [INFO] [stdout] = note: for more information, see issue #27970 [INFO] [stdout] = note: `--force-warn deprecated-safe-2024` implied by `--force-warn rust-2024-compatibility` [INFO] [stdout] help: you can wrap the call in an `unsafe` block if you can guarantee that the environment access only happens in single-threaded code [INFO] [stdout] | [INFO] [stdout] 129 ~ // TODO: Audit that the environment access only happens in single-threaded code. [INFO] [stdout] 130 ~ unsafe { std::env::set_var(AVAHI_COMPAT_NOWARN, "1") }; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 24 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] For more information about this error, try `rustc --explain E0133`. [INFO] [stdout] [INFO] [stderr] Migrating examples/browse.rs from 2021 edition to 2024 [INFO] [stderr] warning: failed to automatically apply fixes suggested by rustc to crate `async_dnssd` [INFO] [stderr] [INFO] [stderr] after fixes were automatically applied the compiler reported errors within these files: [INFO] [stderr] [INFO] [stderr] * src/ffi.rs [INFO] [stderr] [INFO] [stderr] This likely indicates a bug in either rustc or cargo itself, [INFO] [stderr] and we would appreciate a bug report! You're likely to see [INFO] [stderr] a number of compiler warnings after this message which cargo [INFO] [stderr] attempted to fix but failed. If you could open an issue at [INFO] [stderr] https://github.com/rust-lang/rust/issues [INFO] [stderr] quoting the full output of this command we'd be very appreciative! [INFO] [stderr] Note that you may be able to make some more progress in the near-term [INFO] [stderr] fixing code with the `--broken-code` flag [INFO] [stderr] [INFO] [stderr] The following errors were reported: [INFO] [stderr] error[E0658]: fragment specifier `expr_2021` is unstable [INFO] [stderr] --> src/ffi.rs:48:58 [INFO] [stderr] | [INFO] [stderr] 48 | ($(#[$m:meta])* $name:ident : $ty:tt => $($case:ident = $val:expr_2021,)* ) => ( [INFO] [stderr] | ^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: see issue #123742 for more information [INFO] [stderr] = help: add `#![feature(expr_fragment_specifier_2024)]` to the crate attributes to enable [INFO] [stderr] = note: this compiler was built on 2024-09-17; consider upgrading it if it is out of date [INFO] [stderr] [INFO] [stderr] error: aborting due to 1 previous error [INFO] [stderr] [INFO] [stderr] For more information about this error, try `rustc --explain E0658`. [INFO] [stderr] Original diagnostics will follow. [INFO] [stderr] [INFO] [stdout] warning: the `expr` fragment specifier will accept more expressions in the 2024 edition [INFO] [stdout] --> src/ffi.rs:48:63 [INFO] [stdout] | [INFO] [stdout] 48 | ($(#[$m:meta])* $name:ident : $ty:tt => $($case:ident = $val:expr,)* ) => ( [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = warning: this changes meaning in Rust 2024 [INFO] [stdout] = note: for more information, see Migration Guide [INFO] [stdout] = note: `--force-warn edition-2024-expr-fragment-specifier` implied by `--force-warn rust-2024-compatibility` [INFO] [stdout] help: to keep the existing behavior, use the `expr_2021` fragment specifier [INFO] [stdout] | [INFO] [stdout] 48 | ($(#[$m:meta])* $name:ident : $ty:tt => $($case:ident = $val:expr_2021,)* ) => ( [INFO] [stdout] | ~~~~~~~~~ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: extern blocks should be unsafe [INFO] [stdout] --> src/ffi.rs:184:1 [INFO] [stdout] | [INFO] [stdout] 184 | extern "C" { [INFO] [stdout] | ^ [INFO] [stdout] | | [INFO] [stdout] | _help: needs `unsafe` before the extern keyword: `unsafe` [INFO] [stdout] | | [INFO] [stdout] 185 | | pub fn DNSServiceRefSockFD(sd_ref: DNSServiceRef) -> c_int; [INFO] [stdout] 186 | | pub fn DNSServiceProcessResult(sd_ref: DNSServiceRef) -> DNSServiceErrorType; [INFO] [stdout] 187 | | pub fn DNSServiceRefDeallocate(sd_ref: DNSServiceRef); [INFO] [stdout] ... | [INFO] [stdout] 289 | | ) -> c_int; [INFO] [stdout] 290 | | } [INFO] [stdout] | |_^ [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024! [INFO] [stdout] = note: for more information, see issue #123743 [INFO] [stdout] = note: `--force-warn missing-unsafe-on-extern` implied by `--force-warn rust-2024-compatibility` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `std::ffi::CStr::from_ptr` is unsafe and requires unsafe block [INFO] [stdout] --> src/cstr.rs:10:2 [INFO] [stdout] | [INFO] [stdout] 10 | ffi::CStr::from_ptr(s) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/cstr.rs:9:1 [INFO] [stdout] | [INFO] [stdout] 9 | pub unsafe fn from_cstr(s: *const c_char) -> io::Result<&'static str> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] = note: `--force-warn unsafe-op-in-unsafe-fn` implied by `--force-warn rust-2024-compatibility` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: dereference of raw pointer is unsafe and requires unsafe block [INFO] [stdout] --> src/future.rs:46:46 [INFO] [stdout] | [INFO] [stdout] 46 | let sender: &mut CallbackContext = &mut *sender; [INFO] [stdout] | ^^^^^^^ dereference of raw pointer [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/future.rs:37:2 [INFO] [stdout] | [INFO] [stdout] 37 | / pub(crate) unsafe fn run_callback( [INFO] [stdout] 38 | | context: *mut c_void, [INFO] [stdout] 39 | | error_code: ffi::DNSServiceErrorType, [INFO] [stdout] 40 | | f: F, [INFO] [stdout] 41 | | ) where [INFO] [stdout] 42 | | F: FnOnce() -> io::Result, [INFO] [stdout] 43 | | T: ::std::fmt::Debug, [INFO] [stdout] | |_____________________________^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `stream::ServiceStream::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/browse.rs:104:2 [INFO] [stdout] | [INFO] [stdout] 104 | / CallbackStream::run_callback(context, error_code, || { [INFO] [stdout] 105 | | let service_name = cstr::from_cstr(service_name)?; [INFO] [stdout] 106 | | let reg_type = cstr::from_cstr(reg_type)?; [INFO] [stdout] 107 | | let reply_domain = cstr::from_cstr(reply_domain)?; [INFO] [stdout] ... | [INFO] [stdout] 115 | | }) [INFO] [stdout] 116 | | }); [INFO] [stdout] | |______^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/browse.rs:94:1 [INFO] [stdout] | [INFO] [stdout] 94 | / unsafe extern "C" fn browse_callback( [INFO] [stdout] 95 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 96 | | flags: ffi::DNSServiceFlags, [INFO] [stdout] 97 | | interface_index: u32, [INFO] [stdout] ... | [INFO] [stdout] 102 | | context: *mut c_void, [INFO] [stdout] 103 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/browse.rs:105:22 [INFO] [stdout] | [INFO] [stdout] 105 | let service_name = cstr::from_cstr(service_name)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/browse.rs:106:18 [INFO] [stdout] | [INFO] [stdout] 106 | let reg_type = cstr::from_cstr(reg_type)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/browse.rs:107:22 [INFO] [stdout] | [INFO] [stdout] 107 | let reply_domain = cstr::from_cstr(reply_domain)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `future::ServiceFuture::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/connection.rs:93:2 [INFO] [stdout] | [INFO] [stdout] 93 | CallbackFuture::run_callback(context, error_code, || Ok(RegisterRecordResult)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/connection.rs:86:1 [INFO] [stdout] | [INFO] [stdout] 86 | / unsafe extern "C" fn register_record_callback( [INFO] [stdout] 87 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 88 | | _record_ref: ffi::DNSRecordRef, [INFO] [stdout] 89 | | _flags: ffi::DNSServiceFlags, [INFO] [stdout] 90 | | error_code: ffi::DNSServiceErrorType, [INFO] [stdout] 91 | | context: *mut c_void, [INFO] [stdout] 92 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `stream::ServiceStream::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/enumerate_domains.rs:104:2 [INFO] [stdout] | [INFO] [stdout] 104 | / CallbackStream::run_callback(context, error_code, || { [INFO] [stdout] 105 | | let reply_domain = cstr::from_cstr(reply_domain)?; [INFO] [stdout] 106 | | [INFO] [stdout] 107 | | Ok(EnumerateResult { [INFO] [stdout] ... | [INFO] [stdout] 111 | | }) [INFO] [stdout] 112 | | }); [INFO] [stdout] | |______^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/enumerate_domains.rs:96:1 [INFO] [stdout] | [INFO] [stdout] 96 | / unsafe extern "C" fn enumerate_callback( [INFO] [stdout] 97 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 98 | | flags: ffi::DNSServiceFlags, [INFO] [stdout] 99 | | interface_index: u32, [INFO] [stdout] ... | [INFO] [stdout] 102 | | context: *mut c_void, [INFO] [stdout] 103 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/enumerate_domains.rs:105:22 [INFO] [stdout] | [INFO] [stdout] 105 | let reply_domain = cstr::from_cstr(reply_domain)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `stream::ServiceStream::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/query_record.rs:108:2 [INFO] [stdout] | [INFO] [stdout] 108 | / CallbackStream::run_callback(context, error_code, || { [INFO] [stdout] 109 | | let fullname = cstr::from_cstr(fullname)?; [INFO] [stdout] 110 | | let rdata = ::std::slice::from_raw_parts(rdata, rd_len as usize); [INFO] [stdout] ... | [INFO] [stdout] 120 | | }) [INFO] [stdout] 121 | | }); [INFO] [stdout] | |______^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/query_record.rs:95:1 [INFO] [stdout] | [INFO] [stdout] 95 | / unsafe extern "C" fn query_record_callback( [INFO] [stdout] 96 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 97 | | flags: ffi::DNSServiceFlags, [INFO] [stdout] 98 | | interface_index: u32, [INFO] [stdout] ... | [INFO] [stdout] 106 | | context: *mut c_void, [INFO] [stdout] 107 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/query_record.rs:109:18 [INFO] [stdout] | [INFO] [stdout] 109 | let fullname = cstr::from_cstr(fullname)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `std::slice::from_raw_parts` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/query_record.rs:110:15 [INFO] [stdout] | [INFO] [stdout] 110 | let rdata = ::std::slice::from_raw_parts(rdata, rd_len as usize); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `future::ServiceFuture::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/register.rs:149:2 [INFO] [stdout] | [INFO] [stdout] 149 | / CallbackFuture::run_callback(context, error_code, || { [INFO] [stdout] 150 | | let name = cstr::from_cstr(name)?; [INFO] [stdout] 151 | | let reg_type = cstr::from_cstr(reg_type)?; [INFO] [stdout] 152 | | let domain = cstr::from_cstr(domain)?; [INFO] [stdout] ... | [INFO] [stdout] 158 | | }) [INFO] [stdout] 159 | | }); [INFO] [stdout] | |______^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/register.rs:140:1 [INFO] [stdout] | [INFO] [stdout] 140 | / unsafe extern "C" fn register_callback( [INFO] [stdout] 141 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 142 | | _flags: ffi::DNSServiceFlags, [INFO] [stdout] 143 | | error_code: ffi::DNSServiceErrorType, [INFO] [stdout] ... | [INFO] [stdout] 147 | | context: *mut c_void, [INFO] [stdout] 148 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/register.rs:150:14 [INFO] [stdout] | [INFO] [stdout] 150 | let name = cstr::from_cstr(name)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/register.rs:151:18 [INFO] [stdout] | [INFO] [stdout] 151 | let reg_type = cstr::from_cstr(reg_type)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/register.rs:152:16 [INFO] [stdout] | [INFO] [stdout] 152 | let domain = cstr::from_cstr(domain)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `stream::ServiceStream::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/resolve.rs:100:2 [INFO] [stdout] | [INFO] [stdout] 100 | / CallbackStream::run_callback(context, error_code, || { [INFO] [stdout] 101 | | let fullname = cstr::from_cstr(fullname)?; [INFO] [stdout] 102 | | let host_target = cstr::from_cstr(host_target)?; [INFO] [stdout] 103 | | let txt = ::std::slice::from_raw_parts(txt_record, txt_len as usize); [INFO] [stdout] ... | [INFO] [stdout] 112 | | }) [INFO] [stdout] 113 | | }); [INFO] [stdout] | |______^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/resolve.rs:88:1 [INFO] [stdout] | [INFO] [stdout] 88 | / unsafe extern "C" fn resolve_callback( [INFO] [stdout] 89 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 90 | | flags: ffi::DNSServiceFlags, [INFO] [stdout] 91 | | interface_index: u32, [INFO] [stdout] ... | [INFO] [stdout] 98 | | context: *mut c_void, [INFO] [stdout] 99 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/resolve.rs:101:18 [INFO] [stdout] | [INFO] [stdout] 101 | let fullname = cstr::from_cstr(fullname)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/resolve.rs:102:21 [INFO] [stdout] | [INFO] [stdout] 102 | let host_target = cstr::from_cstr(host_target)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `std::slice::from_raw_parts` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/resolve.rs:103:13 [INFO] [stdout] | [INFO] [stdout] 103 | let txt = ::std::slice::from_raw_parts(txt_record, txt_len as usize); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: dereference of raw pointer is unsafe and requires unsafe block [INFO] [stdout] --> src/stream.rs:43:46 [INFO] [stdout] | [INFO] [stdout] 43 | let sender: &mut CallbackContext = &mut *sender; [INFO] [stdout] | ^^^^^^^ dereference of raw pointer [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/stream.rs:34:2 [INFO] [stdout] | [INFO] [stdout] 34 | / pub(crate) unsafe fn run_callback( [INFO] [stdout] 35 | | context: *mut c_void, [INFO] [stdout] 36 | | error_code: ffi::DNSServiceErrorType, [INFO] [stdout] 37 | | f: F, [INFO] [stdout] 38 | | ) where [INFO] [stdout] 39 | | F: FnOnce() -> io::Result, [INFO] [stdout] 40 | | T: ::std::fmt::Debug, [INFO] [stdout] | |_____________________________^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: call to deprecated safe function `std::env::set_var` is unsafe and requires unsafe block [INFO] [stdout] --> src/lib.rs:129:5 [INFO] [stdout] | [INFO] [stdout] 129 | std::env::set_var(AVAHI_COMPAT_NOWARN, "1"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024! [INFO] [stdout] = note: for more information, see issue #27970 [INFO] [stdout] = note: `--force-warn deprecated-safe-2024` implied by `--force-warn rust-2024-compatibility` [INFO] [stdout] help: you can wrap the call in an `unsafe` block if you can guarantee that the environment access only happens in single-threaded code [INFO] [stdout] | [INFO] [stdout] 129 ~ // TODO: Audit that the environment access only happens in single-threaded code. [INFO] [stdout] 130 ~ unsafe { std::env::set_var(AVAHI_COMPAT_NOWARN, "1") }; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 24 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] For more information about this error, try `rustc --explain E0133`. [INFO] [stdout] [INFO] [stderr] Fixed examples/browse.rs (2 fixes) [INFO] [stderr] Migrating examples/register.rs from 2021 edition to 2024 [INFO] [stderr] Migrating examples/enumerate-domains.rs from 2021 edition to 2024 [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 6.64s [INFO] [stderr] Running `cargo check` to verify 2024 [INFO] [stderr] Compiling async-dnssd v0.5.1 (/tmp/fixit) [INFO] [stdout] error: extern blocks must be unsafe [INFO] [stdout] --> src/ffi.rs:184:1 [INFO] [stdout] | [INFO] [stdout] 184 | / extern "C" { [INFO] [stdout] 185 | | pub fn DNSServiceRefSockFD(sd_ref: DNSServiceRef) -> c_int; [INFO] [stdout] 186 | | pub fn DNSServiceProcessResult(sd_ref: DNSServiceRef) -> DNSServiceErrorType; [INFO] [stdout] 187 | | pub fn DNSServiceRefDeallocate(sd_ref: DNSServiceRef); [INFO] [stdout] ... | [INFO] [stdout] 289 | | ) -> c_int; [INFO] [stdout] 290 | | } [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: extern blocks must be unsafe [INFO] [stdout] --> src/ffi.rs:184:1 [INFO] [stdout] | [INFO] [stdout] 184 | / extern "C" { [INFO] [stdout] 185 | | pub fn DNSServiceRefSockFD(sd_ref: DNSServiceRef) -> c_int; [INFO] [stdout] 186 | | pub fn DNSServiceProcessResult(sd_ref: DNSServiceRef) -> DNSServiceErrorType; [INFO] [stdout] 187 | | pub fn DNSServiceRefDeallocate(sd_ref: DNSServiceRef); [INFO] [stdout] ... | [INFO] [stdout] 289 | | ) -> c_int; [INFO] [stdout] 290 | | } [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `std::ffi::CStr::from_ptr` is unsafe and requires unsafe block [INFO] [stdout] --> src/cstr.rs:10:2 [INFO] [stdout] | [INFO] [stdout] 10 | ffi::CStr::from_ptr(s) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/cstr.rs:9:1 [INFO] [stdout] | [INFO] [stdout] 9 | pub unsafe fn from_cstr(s: *const c_char) -> io::Result<&'static str> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] = note: `#[warn(unsafe_op_in_unsafe_fn)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: dereference of raw pointer is unsafe and requires unsafe block [INFO] [stdout] --> src/future.rs:46:46 [INFO] [stdout] | [INFO] [stdout] 46 | let sender: &mut CallbackContext = &mut *sender; [INFO] [stdout] | ^^^^^^^ dereference of raw pointer [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/future.rs:37:2 [INFO] [stdout] | [INFO] [stdout] 37 | / pub(crate) unsafe fn run_callback( [INFO] [stdout] 38 | | context: *mut c_void, [INFO] [stdout] 39 | | error_code: ffi::DNSServiceErrorType, [INFO] [stdout] 40 | | f: F, [INFO] [stdout] 41 | | ) where [INFO] [stdout] 42 | | F: FnOnce() -> io::Result, [INFO] [stdout] 43 | | T: ::std::fmt::Debug, [INFO] [stdout] | |_____________________________^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `std::ffi::CStr::from_ptr` is unsafe and requires unsafe block [INFO] [stdout] --> src/cstr.rs:10:2 [INFO] [stdout] | [INFO] [stdout] 10 | ffi::CStr::from_ptr(s) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/cstr.rs:9:1 [INFO] [stdout] | [INFO] [stdout] 9 | pub unsafe fn from_cstr(s: *const c_char) -> io::Result<&'static str> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] = note: `#[warn(unsafe_op_in_unsafe_fn)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `stream::ServiceStream::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/browse.rs:104:2 [INFO] [stdout] | [INFO] [stdout] 104 | / CallbackStream::run_callback(context, error_code, || { [INFO] [stdout] 105 | | let service_name = cstr::from_cstr(service_name)?; [INFO] [stdout] 106 | | let reg_type = cstr::from_cstr(reg_type)?; [INFO] [stdout] 107 | | let reply_domain = cstr::from_cstr(reply_domain)?; [INFO] [stdout] ... | [INFO] [stdout] 115 | | }) [INFO] [stdout] 116 | | }); [INFO] [stdout] | |______^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/browse.rs:94:1 [INFO] [stdout] | [INFO] [stdout] 94 | / unsafe extern "C" fn browse_callback( [INFO] [stdout] 95 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 96 | | flags: ffi::DNSServiceFlags, [INFO] [stdout] 97 | | interface_index: u32, [INFO] [stdout] ... | [INFO] [stdout] 102 | | context: *mut c_void, [INFO] [stdout] 103 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/browse.rs:105:22 [INFO] [stdout] | [INFO] [stdout] 105 | let service_name = cstr::from_cstr(service_name)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/browse.rs:106:18 [INFO] [stdout] | [INFO] [stdout] 106 | let reg_type = cstr::from_cstr(reg_type)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/browse.rs:107:22 [INFO] [stdout] | [INFO] [stdout] 107 | let reply_domain = cstr::from_cstr(reply_domain)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: dereference of raw pointer is unsafe and requires unsafe block [INFO] [stdout] --> src/future.rs:46:46 [INFO] [stdout] | [INFO] [stdout] 46 | let sender: &mut CallbackContext = &mut *sender; [INFO] [stdout] | ^^^^^^^ dereference of raw pointer [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/future.rs:37:2 [INFO] [stdout] | [INFO] [stdout] 37 | / pub(crate) unsafe fn run_callback( [INFO] [stdout] 38 | | context: *mut c_void, [INFO] [stdout] 39 | | error_code: ffi::DNSServiceErrorType, [INFO] [stdout] 40 | | f: F, [INFO] [stdout] 41 | | ) where [INFO] [stdout] 42 | | F: FnOnce() -> io::Result, [INFO] [stdout] 43 | | T: ::std::fmt::Debug, [INFO] [stdout] | |_____________________________^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `future::ServiceFuture::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/connection.rs:93:2 [INFO] [stdout] | [INFO] [stdout] 93 | CallbackFuture::run_callback(context, error_code, || Ok(RegisterRecordResult)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/connection.rs:86:1 [INFO] [stdout] | [INFO] [stdout] 86 | / unsafe extern "C" fn register_record_callback( [INFO] [stdout] 87 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 88 | | _record_ref: ffi::DNSRecordRef, [INFO] [stdout] 89 | | _flags: ffi::DNSServiceFlags, [INFO] [stdout] 90 | | error_code: ffi::DNSServiceErrorType, [INFO] [stdout] 91 | | context: *mut c_void, [INFO] [stdout] 92 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `stream::ServiceStream::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/enumerate_domains.rs:104:2 [INFO] [stdout] | [INFO] [stdout] 104 | / CallbackStream::run_callback(context, error_code, || { [INFO] [stdout] 105 | | let reply_domain = cstr::from_cstr(reply_domain)?; [INFO] [stdout] 106 | | [INFO] [stdout] 107 | | Ok(EnumerateResult { [INFO] [stdout] ... | [INFO] [stdout] 111 | | }) [INFO] [stdout] 112 | | }); [INFO] [stdout] | |______^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/enumerate_domains.rs:96:1 [INFO] [stdout] | [INFO] [stdout] 96 | / unsafe extern "C" fn enumerate_callback( [INFO] [stdout] 97 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 98 | | flags: ffi::DNSServiceFlags, [INFO] [stdout] 99 | | interface_index: u32, [INFO] [stdout] ... | [INFO] [stdout] 102 | | context: *mut c_void, [INFO] [stdout] 103 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/enumerate_domains.rs:105:22 [INFO] [stdout] | [INFO] [stdout] 105 | let reply_domain = cstr::from_cstr(reply_domain)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `stream::ServiceStream::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/query_record.rs:108:2 [INFO] [stdout] | [INFO] [stdout] 108 | / CallbackStream::run_callback(context, error_code, || { [INFO] [stdout] 109 | | let fullname = cstr::from_cstr(fullname)?; [INFO] [stdout] 110 | | let rdata = ::std::slice::from_raw_parts(rdata, rd_len as usize); [INFO] [stdout] ... | [INFO] [stdout] 120 | | }) [INFO] [stdout] 121 | | }); [INFO] [stdout] | |______^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/query_record.rs:95:1 [INFO] [stdout] | [INFO] [stdout] 95 | / unsafe extern "C" fn query_record_callback( [INFO] [stdout] 96 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 97 | | flags: ffi::DNSServiceFlags, [INFO] [stdout] 98 | | interface_index: u32, [INFO] [stdout] ... | [INFO] [stdout] 106 | | context: *mut c_void, [INFO] [stdout] 107 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/query_record.rs:109:18 [INFO] [stdout] | [INFO] [stdout] 109 | let fullname = cstr::from_cstr(fullname)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `std::slice::from_raw_parts` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/query_record.rs:110:15 [INFO] [stdout] | [INFO] [stdout] 110 | let rdata = ::std::slice::from_raw_parts(rdata, rd_len as usize); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `stream::ServiceStream::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/browse.rs:104:2 [INFO] [stdout] | [INFO] [stdout] 104 | / CallbackStream::run_callback(context, error_code, || { [INFO] [stdout] 105 | | let service_name = cstr::from_cstr(service_name)?; [INFO] [stdout] 106 | | let reg_type = cstr::from_cstr(reg_type)?; [INFO] [stdout] 107 | | let reply_domain = cstr::from_cstr(reply_domain)?; [INFO] [stdout] ... | [INFO] [stdout] 115 | | }) [INFO] [stdout] 116 | | }); [INFO] [stdout] | |______^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/browse.rs:94:1 [INFO] [stdout] | [INFO] [stdout] 94 | / unsafe extern "C" fn browse_callback( [INFO] [stdout] 95 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 96 | | flags: ffi::DNSServiceFlags, [INFO] [stdout] 97 | | interface_index: u32, [INFO] [stdout] ... | [INFO] [stdout] 102 | | context: *mut c_void, [INFO] [stdout] 103 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/browse.rs:105:22 [INFO] [stdout] | [INFO] [stdout] 105 | let service_name = cstr::from_cstr(service_name)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/browse.rs:106:18 [INFO] [stdout] | [INFO] [stdout] 106 | let reg_type = cstr::from_cstr(reg_type)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/browse.rs:107:22 [INFO] [stdout] | [INFO] [stdout] 107 | let reply_domain = cstr::from_cstr(reply_domain)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `future::ServiceFuture::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/register.rs:149:2 [INFO] [stdout] | [INFO] [stdout] 149 | / CallbackFuture::run_callback(context, error_code, || { [INFO] [stdout] 150 | | let name = cstr::from_cstr(name)?; [INFO] [stdout] 151 | | let reg_type = cstr::from_cstr(reg_type)?; [INFO] [stdout] 152 | | let domain = cstr::from_cstr(domain)?; [INFO] [stdout] ... | [INFO] [stdout] 158 | | }) [INFO] [stdout] 159 | | }); [INFO] [stdout] | |______^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/register.rs:140:1 [INFO] [stdout] | [INFO] [stdout] 140 | / unsafe extern "C" fn register_callback( [INFO] [stdout] 141 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 142 | | _flags: ffi::DNSServiceFlags, [INFO] [stdout] 143 | | error_code: ffi::DNSServiceErrorType, [INFO] [stdout] ... | [INFO] [stdout] 147 | | context: *mut c_void, [INFO] [stdout] 148 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/register.rs:150:14 [INFO] [stdout] | [INFO] [stdout] 150 | let name = cstr::from_cstr(name)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/register.rs:151:18 [INFO] [stdout] | [INFO] [stdout] 151 | let reg_type = cstr::from_cstr(reg_type)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/register.rs:152:16 [INFO] [stdout] | [INFO] [stdout] 152 | let domain = cstr::from_cstr(domain)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `future::ServiceFuture::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/connection.rs:93:2 [INFO] [stdout] | [INFO] [stdout] 93 | CallbackFuture::run_callback(context, error_code, || Ok(RegisterRecordResult)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/connection.rs:86:1 [INFO] [stdout] | [INFO] [stdout] 86 | / unsafe extern "C" fn register_record_callback( [INFO] [stdout] 87 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 88 | | _record_ref: ffi::DNSRecordRef, [INFO] [stdout] 89 | | _flags: ffi::DNSServiceFlags, [INFO] [stdout] 90 | | error_code: ffi::DNSServiceErrorType, [INFO] [stdout] 91 | | context: *mut c_void, [INFO] [stdout] 92 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `stream::ServiceStream::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/resolve.rs:100:2 [INFO] [stdout] | [INFO] [stdout] 100 | / CallbackStream::run_callback(context, error_code, || { [INFO] [stdout] 101 | | let fullname = cstr::from_cstr(fullname)?; [INFO] [stdout] 102 | | let host_target = cstr::from_cstr(host_target)?; [INFO] [stdout] 103 | | let txt = ::std::slice::from_raw_parts(txt_record, txt_len as usize); [INFO] [stdout] ... | [INFO] [stdout] 112 | | }) [INFO] [stdout] 113 | | }); [INFO] [stdout] | |______^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/resolve.rs:88:1 [INFO] [stdout] | [INFO] [stdout] 88 | / unsafe extern "C" fn resolve_callback( [INFO] [stdout] 89 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 90 | | flags: ffi::DNSServiceFlags, [INFO] [stdout] 91 | | interface_index: u32, [INFO] [stdout] ... | [INFO] [stdout] 98 | | context: *mut c_void, [INFO] [stdout] 99 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/resolve.rs:101:18 [INFO] [stdout] | [INFO] [stdout] 101 | let fullname = cstr::from_cstr(fullname)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/resolve.rs:102:21 [INFO] [stdout] | [INFO] [stdout] 102 | let host_target = cstr::from_cstr(host_target)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `std::slice::from_raw_parts` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/resolve.rs:103:13 [INFO] [stdout] | [INFO] [stdout] 103 | let txt = ::std::slice::from_raw_parts(txt_record, txt_len as usize); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `stream::ServiceStream::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/enumerate_domains.rs:104:2 [INFO] [stdout] | [INFO] [stdout] 104 | / CallbackStream::run_callback(context, error_code, || { [INFO] [stdout] 105 | | let reply_domain = cstr::from_cstr(reply_domain)?; [INFO] [stdout] 106 | | [INFO] [stdout] 107 | | Ok(EnumerateResult { [INFO] [stdout] ... | [INFO] [stdout] 111 | | }) [INFO] [stdout] 112 | | }); [INFO] [stdout] | |______^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/enumerate_domains.rs:96:1 [INFO] [stdout] | [INFO] [stdout] 96 | / unsafe extern "C" fn enumerate_callback( [INFO] [stdout] 97 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 98 | | flags: ffi::DNSServiceFlags, [INFO] [stdout] 99 | | interface_index: u32, [INFO] [stdout] ... | [INFO] [stdout] 102 | | context: *mut c_void, [INFO] [stdout] 103 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/enumerate_domains.rs:105:22 [INFO] [stdout] | [INFO] [stdout] 105 | let reply_domain = cstr::from_cstr(reply_domain)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `stream::ServiceStream::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/query_record.rs:108:2 [INFO] [stdout] | [INFO] [stdout] 108 | / CallbackStream::run_callback(context, error_code, || { [INFO] [stdout] 109 | | let fullname = cstr::from_cstr(fullname)?; [INFO] [stdout] 110 | | let rdata = ::std::slice::from_raw_parts(rdata, rd_len as usize); [INFO] [stdout] ... | [INFO] [stdout] 120 | | }) [INFO] [stdout] 121 | | }); [INFO] [stdout] | |______^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/query_record.rs:95:1 [INFO] [stdout] | [INFO] [stdout] 95 | / unsafe extern "C" fn query_record_callback( [INFO] [stdout] 96 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 97 | | flags: ffi::DNSServiceFlags, [INFO] [stdout] 98 | | interface_index: u32, [INFO] [stdout] ... | [INFO] [stdout] 106 | | context: *mut c_void, [INFO] [stdout] 107 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/query_record.rs:109:18 [INFO] [stdout] | [INFO] [stdout] 109 | let fullname = cstr::from_cstr(fullname)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `std::slice::from_raw_parts` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/query_record.rs:110:15 [INFO] [stdout] | [INFO] [stdout] 110 | let rdata = ::std::slice::from_raw_parts(rdata, rd_len as usize); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: dereference of raw pointer is unsafe and requires unsafe block [INFO] [stdout] --> src/stream.rs:43:46 [INFO] [stdout] | [INFO] [stdout] 43 | let sender: &mut CallbackContext = &mut *sender; [INFO] [stdout] | ^^^^^^^ dereference of raw pointer [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/stream.rs:34:2 [INFO] [stdout] | [INFO] [stdout] 34 | / pub(crate) unsafe fn run_callback( [INFO] [stdout] 35 | | context: *mut c_void, [INFO] [stdout] 36 | | error_code: ffi::DNSServiceErrorType, [INFO] [stdout] 37 | | f: F, [INFO] [stdout] 38 | | ) where [INFO] [stdout] 39 | | F: FnOnce() -> io::Result, [INFO] [stdout] 40 | | T: ::std::fmt::Debug, [INFO] [stdout] | |_____________________________^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `future::ServiceFuture::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/register.rs:149:2 [INFO] [stdout] | [INFO] [stdout] 149 | / CallbackFuture::run_callback(context, error_code, || { [INFO] [stdout] 150 | | let name = cstr::from_cstr(name)?; [INFO] [stdout] 151 | | let reg_type = cstr::from_cstr(reg_type)?; [INFO] [stdout] 152 | | let domain = cstr::from_cstr(domain)?; [INFO] [stdout] ... | [INFO] [stdout] 158 | | }) [INFO] [stdout] 159 | | }); [INFO] [stdout] | |______^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/register.rs:140:1 [INFO] [stdout] | [INFO] [stdout] 140 | / unsafe extern "C" fn register_callback( [INFO] [stdout] 141 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 142 | | _flags: ffi::DNSServiceFlags, [INFO] [stdout] 143 | | error_code: ffi::DNSServiceErrorType, [INFO] [stdout] ... | [INFO] [stdout] 147 | | context: *mut c_void, [INFO] [stdout] 148 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/register.rs:150:14 [INFO] [stdout] | [INFO] [stdout] 150 | let name = cstr::from_cstr(name)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/register.rs:151:18 [INFO] [stdout] | [INFO] [stdout] 151 | let reg_type = cstr::from_cstr(reg_type)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/register.rs:152:16 [INFO] [stdout] | [INFO] [stdout] 152 | let domain = cstr::from_cstr(domain)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0133]: call to unsafe function `set_var` is unsafe and requires unsafe block [INFO] [stdout] --> src/lib.rs:129:5 [INFO] [stdout] | [INFO] [stdout] 129 | std::env::set_var(AVAHI_COMPAT_NOWARN, "1"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `stream::ServiceStream::::run_callback` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/resolve.rs:100:2 [INFO] [stdout] | [INFO] [stdout] 100 | / CallbackStream::run_callback(context, error_code, || { [INFO] [stdout] 101 | | let fullname = cstr::from_cstr(fullname)?; [INFO] [stdout] 102 | | let host_target = cstr::from_cstr(host_target)?; [INFO] [stdout] 103 | | let txt = ::std::slice::from_raw_parts(txt_record, txt_len as usize); [INFO] [stdout] ... | [INFO] [stdout] 112 | | }) [INFO] [stdout] 113 | | }); [INFO] [stdout] | |______^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/service/resolve.rs:88:1 [INFO] [stdout] | [INFO] [stdout] 88 | / unsafe extern "C" fn resolve_callback( [INFO] [stdout] 89 | | _sd_ref: ffi::DNSServiceRef, [INFO] [stdout] 90 | | flags: ffi::DNSServiceFlags, [INFO] [stdout] 91 | | interface_index: u32, [INFO] [stdout] ... | [INFO] [stdout] 98 | | context: *mut c_void, [INFO] [stdout] 99 | | ) { [INFO] [stdout] | |_^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/resolve.rs:101:18 [INFO] [stdout] | [INFO] [stdout] 101 | let fullname = cstr::from_cstr(fullname)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `cstr::from_cstr` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/resolve.rs:102:21 [INFO] [stdout] | [INFO] [stdout] 102 | let host_target = cstr::from_cstr(host_target)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning[E0133]: call to unsafe function `std::slice::from_raw_parts` is unsafe and requires unsafe block [INFO] [stdout] --> src/service/resolve.rs:103:13 [INFO] [stdout] | [INFO] [stdout] 103 | let txt = ::std::slice::from_raw_parts(txt_record, txt_len as usize); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: aborting due to 2 previous errors; 21 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] For more information about this error, try `rustc --explain E0133`. [INFO] [stdout] [INFO] [stdout] warning[E0133]: dereference of raw pointer is unsafe and requires unsafe block [INFO] [stdout] --> src/stream.rs:43:46 [INFO] [stdout] | [INFO] [stdout] 43 | let sender: &mut CallbackContext = &mut *sender; [INFO] [stdout] | ^^^^^^^ dereference of raw pointer [INFO] [stdout] | [INFO] [stdout] = note: for more information, see issue #71668 [INFO] [stdout] = note: raw pointers may be null, dangling or unaligned; they can violate aliasing rules and cause data races: all of these are undefined behavior [INFO] [stdout] note: an unsafe function restricts its caller, but its body is safe by default [INFO] [stdout] --> src/stream.rs:34:2 [INFO] [stdout] | [INFO] [stdout] 34 | / pub(crate) unsafe fn run_callback( [INFO] [stdout] 35 | | context: *mut c_void, [INFO] [stdout] 36 | | error_code: ffi::DNSServiceErrorType, [INFO] [stdout] 37 | | f: F, [INFO] [stdout] 38 | | ) where [INFO] [stdout] 39 | | F: FnOnce() -> io::Result, [INFO] [stdout] 40 | | T: ::std::fmt::Debug, [INFO] [stdout] | |_____________________________^ [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] error: could not compile `async-dnssd` (lib test) due to 3 previous errors; 21 warnings emitted [INFO] [stderr] warning: build failed, waiting for other jobs to finish... [INFO] [stdout] error[E0133]: call to unsafe function `set_var` is unsafe and requires unsafe block [INFO] [stdout] --> src/lib.rs:129:5 [INFO] [stdout] | [INFO] [stdout] 129 | std::env::set_var(AVAHI_COMPAT_NOWARN, "1"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function [INFO] [stdout] | [INFO] [stdout] = note: consult the function's documentation for information on how to avoid undefined behavior [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: aborting due to 2 previous errors; 21 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] For more information about this error, try `rustc --explain E0133`. [INFO] [stdout] [INFO] [stderr] error: could not compile `async-dnssd` (lib) due to 3 previous errors; 21 warnings emitted [INFO] [stderr] error: failed to check after updating to 2024 [INFO] [stderr] [INFO] [stderr] Caused by: [INFO] [stderr] process didn't exit successfully: `cargo check --frozen --all --all-targets --message-format=json` (exit status: 101) [INFO] running `Command { std: "docker" "inspect" "d44565cd572c677838ced8c36b2b69b07898c7ac7a637b627a2b70307e01e2a0", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "d44565cd572c677838ced8c36b2b69b07898c7ac7a637b627a2b70307e01e2a0", kill_on_drop: false }` [INFO] [stdout] d44565cd572c677838ced8c36b2b69b07898c7ac7a637b627a2b70307e01e2a0