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.
1 parent d8800c0 commit e39229dCopy full SHA for e39229d
cpp/ql/src/Critical/MissingCheckScanf.ql
@@ -25,12 +25,9 @@ class ScanfOutput extends Expr {
25
ValueNumber valNum;
26
27
ScanfOutput() {
28
- this = call.getOutputArgument(varargIndex) and
29
- instr.getUnconvertedResultExpression() = this and
30
- valueNumber(instr) = valNum and
31
- // The following line is a kludge to prohibit more than one associated `instr` field,
32
- // as would occur, for example, when `this` is an access to an array variable.
33
- not instr instanceof ConvertInstruction
+ this = call.getOutputArgument(varargIndex).getFullyConverted() and
+ instr.getConvertedResultExpression() = this and
+ valueNumber(instr) = valNum
34
}
35
36
ScanfFunctionCall getCall() { result = call }
0 commit comments