We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents a5b2549 + f748417 commit 8b1892dCopy full SHA for 8b1892d
cpp/ql/src/semmle/code/cpp/commons/Alloc.qll
@@ -51,7 +51,11 @@ predicate allocationFunction(Function f) {
51
name = "HeapReAlloc" or
52
name = "VirtualAlloc" or
53
name = "CoTaskMemAlloc" or
54
- name = "CoTaskMemRealloc"
+ name = "CoTaskMemRealloc" or
55
+ name = "kmem_alloc" or
56
+ name = "kmem_zalloc" or
57
+ name = "pool_get" or
58
+ name = "pool_cache_get"
59
)
60
61
}
@@ -77,6 +81,12 @@ predicate freeFunction(Function f, int argNum) {
77
81
name = "free" and argNum = 0
78
82
or
79
83
name = "realloc" and argNum = 0
84
+ or
85
+ name = "kmem_free" and argNum = 0
86
87
+ name = "pool_put" and argNum = 1
88
89
+ name = "pool_cache_put" and argNum = 1
80
90
91
92
f.hasGlobalOrStdName(name) and
0 commit comments