rtl88x2CS: Fix pointer-bool-conversion errors
authorBruno Martins <bgcngm@gmail.com>
Sun, 22 Oct 2023 16:38:33 +0000 (17:38 +0100)
committerBruno Martins <bgcngm@gmail.com>
Sun, 22 Oct 2023 16:41:55 +0000 (17:41 +0100)
Change-Id: I4acf2ad58ec31438216715589af8c75d3ae18fbf

rtl88x2CS/core/rtw_ap.c

index 048d108332eb7983b37d79f545201328bd818d6e..d0c9ec8203454aed706dacaffeca5c57976913d5 100644 (file)
@@ -4381,7 +4381,7 @@ static u8 rtw_ap_update_chbw_by_ifbmp(struct dvobj_priv *dvobj, u8 ifbmp
        int i;
 
        for (i = 0; i < dvobj->iface_nums; i++) {
-               if (!(ifbmp & BIT(i)) || !dvobj->padapters)
+               if (!(ifbmp & BIT(i)) || !dvobj->padapters[i])
                        continue;
 
                iface = dvobj->padapters[i];
@@ -4401,7 +4401,7 @@ static u8 rtw_ap_update_chbw_by_ifbmp(struct dvobj_priv *dvobj, u8 ifbmp
        }
 
        for (i = 0; i < dvobj->iface_nums; i++) {
-               if (!(ifbmp & BIT(i)) || !dvobj->padapters)
+               if (!(ifbmp & BIT(i)) || !dvobj->padapters[i])
                        continue;
 
                iface = dvobj->padapters[i];