From a12e7fece1fbe2f46cdea51d77e69f6801841b0e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?D=C3=A1niel=20Buga?= Date: Mon, 16 Dec 2024 12:53:45 +0100 Subject: [PATCH] Fix WIFI_EVENT (#2817) * Fix WIFI_EVENT * Update esp-wifi/src/common_adapter/mod.rs Co-authored-by: Dominic Fischer <14130965+Dominaezzz@users.noreply.github.com> --------- Co-authored-by: Dominic Fischer <14130965+Dominaezzz@users.noreply.github.com> --- esp-wifi/src/common_adapter/mod.rs | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/esp-wifi/src/common_adapter/mod.rs b/esp-wifi/src/common_adapter/mod.rs index 67bf299889e..2a1e5d9da89 100644 --- a/esp-wifi/src/common_adapter/mod.rs +++ b/esp-wifi/src/common_adapter/mod.rs @@ -1,5 +1,3 @@ -use core::ptr::addr_of; - use esp_wifi_sys::include::timeval; use hal::macros::ram; @@ -201,10 +199,8 @@ pub unsafe extern "C" fn puts(s: *const u8) { } // #define ESP_EVENT_DEFINE_BASE(id) esp_event_base_t id = #id -static mut EVT: i8 = 0; #[no_mangle] -#[allow(unused_unsafe)] -static mut WIFI_EVENT: esp_event_base_t = unsafe { addr_of!(EVT) }; +static mut WIFI_EVENT: esp_event_base_t = c"WIFI_EVENT".as_ptr(); // stuff needed by wpa-supplicant #[no_mangle]