File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed
cpp/ql/src/semmle/code/cpp/dataflow/internal Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -490,7 +490,7 @@ module FlowVar_internal {
490
490
exists ( VariableAccess va |
491
491
va .getTarget ( ) = result and
492
492
readAccess ( va ) and
493
- bbNotInLoop ( va .getBasicBlock ( ) )
493
+ exists ( BasicBlock bb | bb = va .getBasicBlock ( ) | not this . bbInLoop ( bb ) )
494
494
)
495
495
}
496
496
@@ -679,10 +679,11 @@ module FlowVar_internal {
679
679
predicate dominatedByOverwrite ( UninitializedLocalVariable v , VariableAccess va ) {
680
680
exists ( BasicBlock bb , int vaIndex |
681
681
va = bb .getNode ( vaIndex ) and
682
- va .getTarget ( ) = v
683
- |
682
+ va .getTarget ( ) = v and
684
683
vaIndex > indexOfFirstOverwriteInBB ( v , bb )
685
684
or
685
+ va = bb .getNode ( vaIndex ) and
686
+ va .getTarget ( ) = v and
686
687
bbStrictlyDominates ( getAnOverwritingBB ( v ) , bb )
687
688
)
688
689
}
You can’t perform that action at this time.
0 commit comments