From 73e183426f8f3c2a3e030bf63c2112f7a080ded8 Mon Sep 17 00:00:00 2001 From: Elena Oat Date: Mon, 3 Mar 2014 23:34:46 +0200 Subject: Staging: rtl8188eu: Fix warning of kfree check is not required. This patch fixes the warning produced by checkpatch in the file rtw_cmd.c "kfree(NULL) is safe this check is probably not required". The patch fixes it in two places for this file. Signed-off-by: Elena Oat Acked-by: Paul E. McKenney Signed-off-by: Greg Kroah-Hartman --- drivers/staging/rtl8188eu/core/rtw_cmd.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'drivers/staging/rtl8188eu') diff --git a/drivers/staging/rtl8188eu/core/rtw_cmd.c b/drivers/staging/rtl8188eu/core/rtw_cmd.c index 0cab7152a51c..976f000d0f51 100644 --- a/drivers/staging/rtl8188eu/core/rtw_cmd.c +++ b/drivers/staging/rtl8188eu/core/rtw_cmd.c @@ -114,11 +114,8 @@ void _rtw_free_cmd_priv(struct cmd_priv *pcmdpriv) { if (pcmdpriv) { - if (pcmdpriv->cmd_allocated_buf) - kfree(pcmdpriv->cmd_allocated_buf); - - if (pcmdpriv->rsp_allocated_buf) - kfree(pcmdpriv->rsp_allocated_buf); + kfree(pcmdpriv->cmd_allocated_buf); + kfree(pcmdpriv->rsp_allocated_buf); } } -- cgit v1.2.1