fix: finalize code for DEFCON

remove print statements
switch to async based waiting to improve performance a little on Linux
disable checksums on inbound packets on Linux with smoltcp
This commit is contained in:
Andrew Rioux
2026-08-04 02:07:07 -04:00
parent e6530bcf20
commit a56f6e6cb9
7 changed files with 108 additions and 69 deletions
+1 -7
View File
@@ -69,12 +69,6 @@ impl BeaconAdapter for WindowsAdapter {
&mut size_pointer as *mut _,
);
println!("Size: {size_pointer}");
println!(
"Raw error: {:?}; {err}",
std::io::Error::last_os_error().raw_os_error()
);
if err != 0 && std::io::Error::last_os_error().raw_os_error() != Some(0) {
println!("Erroring out here! {err}");
Err(std::io::Error::last_os_error())?;
@@ -88,7 +82,7 @@ impl BeaconAdapter for WindowsAdapter {
while !current_address.is_null() {
let name = nul_ptr_to_slice((*current_address).AdapterName.0 as *const _).to_vec();
let mtu = (*current_address).Mtu;
let Ok(mac_addr) = &(*current_address).PhysicalAddress
let Ok(mac_addr) = &(&(*current_address).PhysicalAddress)
[..(*current_address).PhysicalAddressLength as usize]
.try_into()
else {