Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 66464b5 + 21c6340 commit 59964bdCopy full SHA for 59964bd
1 file changed
cpp/ql/src/Likely Bugs/Leap Year/UncheckedLeapYearAfterYearModification.ql
@@ -24,7 +24,7 @@ where
24
exists(LeapYearFieldAccess yfacheck |
25
yfacheck.getQualifier() = var.getAnAccess() and
26
yfacheck.isUsedInCorrectLeapYearCheck() and
27
- yfacheck = yfa.getASuccessor*()
+ yfacheck.getBasicBlock() = yfa.getBasicBlock().getASuccessor*()
28
)
29
or
30
// If there is a data flow from the variable that was modified to a function that seems to check for leap year
@@ -50,8 +50,8 @@ where
50
mfa.getQualifier() = var.getAnAccess() and
51
mfa.isModified() and
52
(
53
- mfa = yfa.getASuccessor*() or
54
- yfa = mfa.getASuccessor*()
+ mfa.getBasicBlock() = yfa.getBasicBlock().getASuccessor*() or
+ yfa.getBasicBlock() = mfa.getBasicBlock().getASuccessor+()
55
) and
56
ae = mfa.getEnclosingElement() and
57
ae.getAnOperand().getValue().toInt() = 1
0 commit comments