Skip to content

Commit bd94fe1

Browse files
committed
JS: Explain false positive in test case
1 parent e05e077 commit bd94fe1

File tree

1 file changed

+2
-0
lines changed
  • javascript/ql/test/library-tests/TripleDot

1 file changed

+2
-0
lines changed

javascript/ql/test/library-tests/TripleDot/useuse.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,8 @@ function t9() { // same as t8 but with a SanitizerGuard that isn't just a variab
163163
}
164164

165165
if (typeof obj === "undefined" || typeof obj === "undefined") {
166+
// The shared SSA library expects short-circuiting operators be pre-order in the CFG,
167+
// but in JS they are post-order (as per evaluation order).
166168
sink(obj.field); // $ SPURIOUS: hasTaintFlow=t9.1
167169
} else {
168170
sink(obj.field); // $ hasTaintFlow=t9.1

0 commit comments

Comments
 (0)