mirror of
https://github.com/github/codeql.git
synced 2026-04-29 18:55:14 +02:00
JS: Simplify
This commit is contained in:
@@ -78,12 +78,8 @@ module ResourceExhaustion {
|
||||
exists(DataFlow::SourceNode clazz, DataFlow::InvokeNode invk, int index |
|
||||
clazz = DataFlow::globalVarRef("Buffer") and this = invk.getArgument(index)
|
||||
|
|
||||
exists(string name |
|
||||
invk = clazz.getAMemberCall(name) and
|
||||
(
|
||||
name = ["alloc", "allocUnsafe", "allocUnsafeSlow"] and index = 0 // the buffer size
|
||||
)
|
||||
)
|
||||
invk = clazz.getAMemberCall(["alloc", "allocUnsafe", "allocUnsafeSlow"]) and
|
||||
index = 0 // the buffer size
|
||||
or
|
||||
invk = clazz.getAnInvocation() and
|
||||
(
|
||||
|
||||
Reference in New Issue
Block a user