mirror of
https://github.com/github/codeql.git
synced 2026-04-30 19:26:02 +02:00
Python: Fix remaining deprecation warnings.
This commit is contained in:
@@ -79,7 +79,7 @@ predicate def_is_open(EssaDefinition def, ControlFlowNode open) {
|
||||
passes_open_files(refinement)
|
||||
)
|
||||
or
|
||||
exists(PyNodeRefinement refinement | refinement = def |
|
||||
exists(EssaNodeRefinement refinement | refinement = def |
|
||||
not closes_file(def) and
|
||||
not wraps_file(refinement.getDefiningNode(), refinement.getInput()) and
|
||||
var_is_open(refinement.getInput(), open)
|
||||
|
||||
@@ -155,7 +155,7 @@ abstract class TaintKind extends string {
|
||||
* For example, if this were a kind of string taint
|
||||
* the `result` would be `theStrType()`.
|
||||
*/
|
||||
ClassValue getType() { result.(ClassObjectInternal).getSource() = this.getClass() }
|
||||
ClassValue getType() { none() }
|
||||
|
||||
/**
|
||||
* Gets the boolean values (may be one, neither, or both) that
|
||||
@@ -180,7 +180,10 @@ abstract class TaintKind extends string {
|
||||
TaintKind getTaintForIteration() { none() }
|
||||
|
||||
predicate flowStep(DataFlow::Node fromnode, DataFlow::Node tonode, string edgeLabel) {
|
||||
this.additionalFlowStepVar(fromnode.asVariable(), tonode.asVariable()) and
|
||||
exists(DataFlowExtension::DataFlowVariable v |
|
||||
v = fromnode.asVariable() and
|
||||
v.getASuccessorVariable() = tonode.asVariable()
|
||||
) and
|
||||
edgeLabel = "custom taint variable step"
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user