rsi: fix a dereference on adapter before it has been null checked
The assignment of dev is dereferencing adapter before adapter has been null checked, potentially leading to a null pointer dereference. Fix this by simply moving the assignment of dev to a later point after the sanity null check of adapter. Detected by CoverityScan CID#1398383 ("Dereference before null check") Fixes: dad0d04f ("rsi: Add RS9113 wireless driver") Signed-off-by: NColin Ian King <colin.king@canonical.com> Signed-off-by: NKalle Valo <kvalo@codeaurora.org>
Showing
想要评论请 注册 或 登录