]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
nl80211: Fix conditional checks of nlmsg attributes for NAN publish
authorShivani Baranwal <quic_shivbara@quicinc.com>
Sat, 7 Sep 2024 13:45:42 +0000 (19:15 +0530)
committerJouni Malinen <j@w1.fi>
Wed, 11 Sep 2024 23:58:32 +0000 (02:58 +0300)
Some of the cleanup changes had lost the "goto fail" and broken the
logic. Restore correct behavior.

Fixes: 58f04221fdef ("nl80211: NAN USD commands for offloading")
Signed-off-by: Shivani Baranwal <quic_shivbara@quicinc.com>
src/drivers/driver_nl80211.c

index c8ca9f25100a11e31d57a8cfb983f332ed317383..5c2a721d11bdea26049b28183120974a756e4456 100644 (file)
@@ -13682,6 +13682,7 @@ static int nl80211_nan_publish(void *priv, const u8 *src, int publish_id,
                        params->freq) ||
            add_freq_list(msg, QCA_WLAN_VENDOR_ATTR_USD_CHAN_CONFIG_FREQ_LIST,
                          params->freq_list))
+               goto fail;
        nla_nest_end(msg, attr);
 
        nla_nest_end(msg, container);