[DTV00857290][[DTV][Coverity Scanned Code Defect] 15367: Out-of-bounds write]
[Description]
Fix coverity issues under mgmt/
Fix CID2357471 "Dereference after null check" in
p2pRoleFsmRunEventScanDone()
Change-Id: I69f2ac8667bf4204ff967ccd838e4dc37cdb68da
Signed-off-by: Awk Jiang <awk.jiang@mediatek.com>
Feature: misc
CR-Id: DTV00857290
diff --git a/mgmt/p2p_role_fsm.c b/mgmt/p2p_role_fsm.c
index 5fd9709..9da4d2f 100644
--- a/mgmt/p2p_role_fsm.c
+++ b/mgmt/p2p_role_fsm.c
@@ -1914,7 +1914,7 @@
CNM_DBDC_CAP_T rDbdcCap;
#endif /*CFG_SUPPORT_DBDC*/
- if (prP2pRoleFsmInfo != NULL) {
+ if (prP2pRoleFsmInfo == NULL) {
DBGLOG(P2P, TRACE, "prP2pRoleFsmInfo is NULL\n");
goto error;
}