990-ctrl-make-WNM_AP-functions-dependant-on-CONFIG_AP.patch 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. From f0e9f5aab52b3eab85d28338cc996972ced4c39c Mon Sep 17 00:00:00 2001
  2. From: David Bauer <[email protected]>
  3. Date: Tue, 17 May 2022 23:07:59 +0200
  4. Subject: [PATCH] ctrl: make WNM_AP functions dependant on CONFIG_AP
  5. This fixes linking errors found when compiling wpa_supplicant with
  6. CONFIG_WNM_AP enabled but CONFIG_AP disabled.
  7. Signed-off-by: David Bauer <[email protected]>
  8. ---
  9. wpa_supplicant/ctrl_iface.c | 4 ++--
  10. 1 file changed, 2 insertions(+), 2 deletions(-)
  11. diff --git a/wpa_supplicant/ctrl_iface.c b/wpa_supplicant/ctrl_iface.c
  12. index ac337e0f5..6e23114e6 100644
  13. --- a/wpa_supplicant/ctrl_iface.c
  14. +++ b/wpa_supplicant/ctrl_iface.c
  15. @@ -12185,7 +12185,7 @@ char * wpa_supplicant_ctrl_iface_process(struct wpa_supplicant *wpa_s,
  16. if (wpas_ctrl_iface_coloc_intf_report(wpa_s, buf + 18))
  17. reply_len = -1;
  18. #endif /* CONFIG_WNM */
  19. -#ifdef CONFIG_WNM_AP
  20. +#if defined(CONFIG_AP) && defined(CONFIG_WNM_AP)
  21. } else if (os_strncmp(buf, "DISASSOC_IMMINENT ", 18) == 0) {
  22. if (ap_ctrl_iface_disassoc_imminent(wpa_s, buf + 18))
  23. reply_len = -1;
  24. @@ -12195,7 +12195,7 @@ char * wpa_supplicant_ctrl_iface_process(struct wpa_supplicant *wpa_s,
  25. } else if (os_strncmp(buf, "BSS_TM_REQ ", 11) == 0) {
  26. if (ap_ctrl_iface_bss_tm_req(wpa_s, buf + 11))
  27. reply_len = -1;
  28. -#endif /* CONFIG_WNM_AP */
  29. +#endif /* CONFIG_AP && CONFIG_WNM_AP */
  30. } else if (os_strcmp(buf, "FLUSH") == 0) {
  31. wpa_supplicant_ctrl_iface_flush(wpa_s);
  32. } else if (os_strncmp(buf, "RADIO_WORK ", 11) == 0) {
  33. --
  34. 2.35.1