File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed
swift/ql/test/library-tests/dataflow/taint/libraries Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -144,25 +144,27 @@ func taintCollections(array: inout Array<Int>, contiguousArray: inout Contiguous
144144 sink ( arg: array [ 0 ] ) // $ tainted=142
145145 array. withContiguousStorageIfAvailable ( {
146146 buffer in
147+ sink ( arg: buffer) // $ SPURIOUS: tainted=142
148+ sink ( arg: buffer [ 0 ] ) // $ tainted=142
147149 sink ( arg: array)
148150 sink ( arg: array [ 0 ] ) // $ MISSING: tainted=142
149151 } )
150152
151153 contiguousArray [ 0 ] = source2 ( )
152154 sink ( arg: contiguousArray)
153- sink ( arg: contiguousArray [ 0 ] ) // $ MISSING: tainted=151
155+ sink ( arg: contiguousArray [ 0 ] ) // $ MISSING: tainted=153
154156 contiguousArray. withContiguousStorageIfAvailable ( {
155157 buffer in
156158 sink ( arg: buffer)
157- sink ( arg: buffer [ 0 ] ) // $ MISSING: tainted=151
159+ sink ( arg: buffer [ 0 ] ) // $ MISSING: tainted=153
158160 } )
159161
160162 dictionary [ 0 ] = source2 ( )
161163 sink ( arg: dictionary)
162- sink ( arg: dictionary [ 0 ] !) // $ MISSING: tainted=160
164+ sink ( arg: dictionary [ 0 ] !) // $ MISSING: tainted=162
163165 dictionary. withContiguousStorageIfAvailable ( {
164166 buffer in
165167 sink ( arg: buffer)
166- sink ( arg: buffer [ 0 ] ) // $ MISSING: tainted=160
168+ sink ( arg: buffer [ 0 ] ) // $ MISSING: tainted=162
167169 } )
168170}
You can’t perform that action at this time.
0 commit comments