From: Sunil Ravi Date: Tue, 4 Feb 2025 18:35:46 +0000 (+0000) Subject: nl80211: Fix compilation error due to uninitialized variable X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=58ea0a652958acdafc571f88cfa27d0e6aa04fa7;p=thirdparty%2Fhostap.git nl80211: Fix compilation error due to uninitialized variable nl_flags is not necessarily set here. Fixes: 00c2c20d74ee ("hostapd: Maintain single wpa_driver_nl80211_data (drv) object across interfaces") Signed-off-by: Sunil Ravi --- diff --git a/src/drivers/driver_nl80211.c b/src/drivers/driver_nl80211.c index 665697eb5..85b00af91 100644 --- a/src/drivers/driver_nl80211.c +++ b/src/drivers/driver_nl80211.c @@ -14672,9 +14672,9 @@ static int wpa_driver_get_wiphy_name_handler(struct nl_msg *msg, void *arg) static int wpa_driver_get_phyname(struct wpa_driver_nl80211_data *drv) { struct nl_msg *msg; - u32 feat, nl_flags; + u32 nl_flags = 0; + u32 feat = get_nl80211_protocol_features(drv); - feat = get_nl80211_protocol_features(drv); if (feat & NL80211_PROTOCOL_FEATURE_SPLIT_WIPHY_DUMP) nl_flags = NLM_F_DUMP;