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 f1a0ec2 + 7087904 commit 7859c52Copy full SHA for 7859c52
cpp/ql/src/semmle/code/cpp/commons/Printf.qll
@@ -53,7 +53,12 @@ predicate primitiveVariadicFormatter(
53
(
54
if type = "" then outputParamIndex = -1 else outputParamIndex = 0 // Conveniently, these buffer parameters are all at index 0.
55
) and
56
- not exists(f.getBlock()) // exclude functions with an implementation in the snapshot as they may not be standard implementations.
+ not (
57
+ // exclude functions with an implementation in the snapshot source
58
+ // directory, as they may not be standard implementations.
59
+ exists(f.getBlock()) and
60
+ exists(f.getFile().getRelativePath())
61
+ )
62
}
63
64
private predicate callsVariadicFormatter(
0 commit comments