mirror of
https://github.com/github/codeql.git
synced 2026-04-26 09:15:12 +02:00
Python: Don't pass synthetic class instance to __new__ on class calls
This commit is contained in:
@@ -232,7 +232,7 @@ class Customized:
|
||||
customized = Customized()
|
||||
SINK(Customized.a) #$ MISSING:flow="SOURCE, l:-8 -> customized.a"
|
||||
SINK_F(Customized.b)
|
||||
SINK(customized.a) #$ flow="SOURCE, l:-10 -> customized.a"
|
||||
SINK(customized.a) #$ MISSING: flow="SOURCE, l:-10 -> customized.a"
|
||||
SINK(customized.b) #$ flow="SOURCE, l:-7 -> customized.b"
|
||||
|
||||
|
||||
|
||||
@@ -405,11 +405,11 @@ def test__new__():
|
||||
# well.
|
||||
|
||||
SINK(NewTest.foo) # $ MISSING: flow="SOURCE, l:-10 -> NewTest.foo"
|
||||
SINK(nt.foo) # $ flow="SOURCE, l:-11 -> nt.foo"
|
||||
SINK(nt.foo) # $ MISSING: flow="SOURCE, l:-11 -> nt.foo"
|
||||
|
||||
NewTest.foo = NONSOURCE
|
||||
SINK_F(NewTest.foo)
|
||||
SINK_F(nt.foo) # $ SPURIOUS: flow="SOURCE, l:-15 -> nt.foo"
|
||||
SINK_F(nt.foo)
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# Global scope
|
||||
|
||||
Reference in New Issue
Block a user