linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/4] staging: wilc1000: Modify null check routine
@ 2015-09-17  8:50 Tony Cho
  2015-09-17  8:50 ` [PATCH 2/4] staging: wilc1000: remove warnings on the multiple blank lines uses Tony Cho
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: Tony Cho @ 2015-09-17  8:50 UTC (permalink / raw)
  To: gregkh
  Cc: devel, linux-wireless, johnny.kim, chris.park, rachel.kim,
	tony.cho, glen.lee, leo.kim, austin.shin, adel.noureldin,
	adham.abozaeid, Nicolas.FERRE

From: Leo Kim <leo.kim@atmel.com>

This patch modify null check routine.
- Null check error non return. (Handle_RcvdGnrlAsyncInfo)

Signed-off-by: Leo Kim <leo.kim@atmel.com>
Signed-off-by: Tony Cho <tony.cho@atmel.com>
---
 drivers/staging/wilc1000/host_interface.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/staging/wilc1000/host_interface.c b/drivers/staging/wilc1000/host_interface.c
index 6fdf392..a9eaa8f 100644
--- a/drivers/staging/wilc1000/host_interface.c
+++ b/drivers/staging/wilc1000/host_interface.c
@@ -2403,8 +2403,10 @@ static s32 Handle_RcvdGnrlAsyncInfo(tstrWILC_WFIDrv *drvHandler, tstrRcvdGnrlAsy
 	s32 s32Err = 0;
 	tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *) drvHandler;
 
-	if (pstrWFIDrv == NULL)
+	if (!pstrWFIDrv) {
 		PRINT_ER("Driver handler is NULL\n");
+		return -EFAULT;
+	}
 	PRINT_D(GENERIC_DBG, "Current State = %d,Received state = %d\n", pstrWFIDrv->enuHostIFstate,
 		pstrRcvdGnrlAsyncInfo->pu8Buffer[7]);
 
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2015-09-17  9:31 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-09-17  8:50 [PATCH 1/4] staging: wilc1000: Modify null check routine Tony Cho
2015-09-17  8:50 ` [PATCH 2/4] staging: wilc1000: remove warnings on the multiple blank lines uses Tony Cho
2015-09-17  8:50 ` [PATCH 3/4] staging: wilc1000: remove warnings line over 80 characters Tony Cho
2015-09-17  8:50 ` [PATCH 4/4] staging: wilc1000: wilc_wlan_if.h align defines Tony Cho
2015-09-17  9:06 ` [PATCH 1/4] staging: wilc1000: Modify null check routine Nicolas Ferre
2015-09-17  9:31   ` Tony Cho

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).