OSDN Git Service

staging: rtl8723bs: Remove comparison to NULL
authorWambui Karuga <wambui.karugax@gmail.com>
Thu, 10 Oct 2019 13:20:58 +0000 (16:20 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 13 Oct 2019 08:00:35 +0000 (10:00 +0200)
Remove comparison to NULL in drivers/staging/rtl8723bs/core/rtw_ap.c:1449.
Issue found by checkpatch.pl

Signed-off-by: Wambui Karuga <wambui.karugax@gmail.com>
Link: https://lore.kernel.org/r/20191010132058.20887-1-wambui.karugax@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/rtl8723bs/core/rtw_ap.c

index 80027ac..7117d16 100644 (file)
@@ -1447,7 +1447,7 @@ u8 rtw_ap_set_pairwise_key(struct adapter *padapter, struct sta_info *psta)
        u8 res = _SUCCESS;
 
        ph2c = rtw_zmalloc(sizeof(struct cmd_obj));
-       if (ph2c == NULL) {
+       if (!ph2c) {
                res = _FAIL;
                goto exit;
        }