Fix checkpatch warning:
WARNING: kfree(NULL) is safe this check is probably not required

Cc: Greg Kroah-Hartman <[email protected]>
Cc: Sarah Sharp <[email protected]>
Cc: [email protected]
Signed-off-by: Fabian Frederick <[email protected]>
---
 drivers/staging/rtl8821ae/rtl8821ae/hal_btc.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/staging/rtl8821ae/rtl8821ae/hal_btc.c 
b/drivers/staging/rtl8821ae/rtl8821ae/hal_btc.c
index 7b1d113..d8e05c8 100644
--- a/drivers/staging/rtl8821ae/rtl8821ae/hal_btc.c
+++ b/drivers/staging/rtl8821ae/rtl8821ae/hal_btc.c
@@ -2059,8 +2059,7 @@ void rtl_8821ae_c2h_command_handle(struct ieee80211_hw 
*hw)
                break;
        }
 
-       if(ptmp_buf)
-               kfree(ptmp_buf);
+       kfree(ptmp_buf);
 
        rtl_write_byte(rtlpriv, 0x01AF, C2H_EVT_HOST_CLOSE);
 }
-- 
1.8.4.5

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to