File tree Expand file tree Collapse file tree 1 file changed +4
-8
lines changed
go/ql/lib/semmle/go/frameworks/stdlib Expand file tree Collapse file tree 1 file changed +4
-8
lines changed Original file line number Diff line number Diff line change @@ -20,17 +20,13 @@ module IoFs {
2020 private class WalkDirStep extends TaintTracking:: AdditionalTaintStep {
2121 override predicate step ( DataFlow:: Node pred , DataFlow:: Node succ ) {
2222 //signature: func WalkDir(fsys FS, root string, fn WalkDirFunc) error
23- exists ( DataFlow:: CallNode call , DataFlow:: FunctionNode f |
24- f .( DataFlow:: FuncLitNode ) . getASuccessor * ( ) = call . getArgument ( 2 )
23+ exists ( DataFlow:: CallNode call , DataFlow:: FunctionNode f , DataFlow :: Node n |
24+ n = f .( DataFlow:: FuncLitNode )
2525 or
26- exists ( DataFlow:: ExprNode functionName |
27- f .( DataFlow:: GlobalFunctionNode ) .getFunction ( ) =
28- functionName .asExpr ( ) .( FunctionName ) .getTarget ( )
29- |
30- functionName .getASuccessor * ( ) = call .getArgument ( 2 )
31- )
26+ n .asExpr ( ) .( FunctionName ) .getTarget ( ) = f .( DataFlow:: GlobalFunctionNode ) .getFunction ( )
3227 |
3328 call .getTarget ( ) .hasQualifiedName ( packagePath ( ) , "WalkDir" ) and
29+ n .getASuccessor * ( ) = call .getArgument ( 2 ) and
3430 pred = call .getArgument ( 0 ) and
3531 succ = f .getParameter ( [ 0 , 1 ] )
3632 )
You can’t perform that action at this time.
0 commit comments