Update cpp/ql/src/experimental/Security/CWE/CWE-401/MemoryLeakOnFailedCallToRealloc.ql

Co-authored-by: Geoffrey White <40627776+geoffw0@users.noreply.github.com>
This commit is contained in:
ihsinme
2021-01-06 22:23:46 +03:00
committed by GitHub
parent f7eb328f76
commit 2b8227e04d

View File

@@ -14,6 +14,9 @@
import cpp
import semmle.code.cpp.dataflow.DataFlow
/**
* A call to `realloc` of the form `v = realloc(v, size)`, for some variable `v`.
*/
class ReallocCallLeak extends FunctionCall {
ReallocCallLeak() {
exists(AssignExpr ex, Variable v, VariableAccess va1, VariableAccess va2 |