mirror of
https://github.com/github/codeql.git
synced 2025-12-20 18:56:32 +01:00
C++: Ignore gets'es with incorrect parameter counts
This commit is contained in:
@@ -17,5 +17,6 @@ import cpp
|
||||
from FunctionCall call, Function target
|
||||
where
|
||||
call.getTarget() = target and
|
||||
target.hasGlobalOrStdName("gets")
|
||||
target.hasGlobalOrStdName("gets") and
|
||||
target.getNumberOfParameters() = 1
|
||||
select call, "'gets' does not guard against buffer overflow."
|
||||
|
||||
Reference in New Issue
Block a user