Skip to content

Commit da38c90

Browse files
committed
C++: Improvements from PR comments.
1 parent 50c7e47 commit da38c90

File tree

1 file changed

+2
-5
lines changed
  • cpp/ql/src/Security/CWE/CWE-611

1 file changed

+2
-5
lines changed

cpp/ql/src/Security/CWE/CWE-611/XXE.ql

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import semmle.code.cpp.ir.IR
2020
/**
2121
* A flow state representing a possible configuration of an XML object.
2222
*/
23-
abstract class XXEFlowState extends string {
23+
abstract class XXEFlowState extends DataFlow::FlowState {
2424
bindingset[this]
2525
XXEFlowState() { any() } // required characteristic predicate
2626
}
@@ -148,10 +148,7 @@ class CreateEntityReferenceNodesTranformer extends XXEFlowStateTranformer {
148148
* The `AbstractDOMParser.parse` method.
149149
*/
150150
class ParseFunction extends Function {
151-
ParseFunction() {
152-
this.getDeclaringType() instanceof AbstractDOMParserClass and
153-
this.hasName("parse")
154-
}
151+
ParseFunction() { this.getClassAndName("parse") instanceof AbstractDOMParserClass }
155152
}
156153

157154
/**

0 commit comments

Comments
 (0)