staging: ks7010: move null check before dereference
authorTobin C. Harding <me@tobin.cc>
Mon, 10 Apr 2017 03:15:49 +0000 (13:15 +1000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 11 Apr 2017 14:05:50 +0000 (16:05 +0200)
commit9ff19a6e35ab460c07dc40c563b57b0ad866e2e9
treeb91780a6084ea0c2e6a2a653035a7a5d160db568
parentdc59ef2af26de72289b5ac576298445c676f2c5b
staging: ks7010: move null check before dereference

Function parameter is cast to a local pointer which is then
dereferenced before it is checked to be non-NULL.

Move pointer null check to be before the pointer is dereferenced.

Signed-off-by: Tobin C. Harding <me@tobin.cc>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/ks7010/ks_wlan_net.c