Update WrongInDetectingAndHandlingMemoryAllocationErrors.ql

This commit is contained in:
ihsinme
2021-01-29 11:51:15 +03:00
committed by GitHub
parent bdfdcbd673
commit c8eeb5f73e

View File

@@ -22,6 +22,9 @@ class IfCompareWithZero extends IfStmt {
or
this.getCondition().(NEExpr).getAChild().getValue() = "0" and
this.hasElse()
or
this.getCondition().(NEExpr).getAChild().getValue() = "0" and
this.getThen().getAChild*() instanceof ReturnStmt
}
}