Download tasks/codeql_java_benchmark_top30_v2/morefixes-04bdb708bf23aabdc444/patch.diff from Benchanything/checkerbench: direct link, hf CLI and curl.
- Browser
- Download file 2.15 kB
-
https://huggingface.co/datasets/Benchanything/checkerbench/resolve/main/tasks/codeql_java_benchmark_top30_v2/morefixes-04bdb708bf23aabdc444/patch.diff
- Command line
-
hf download hf://datasets/Benchanything/checkerbench/tasks/codeql_java_benchmark_top30_v2/morefixes-04bdb708bf23aabdc444/patch.diff
-
curl -L -o patch.diff https://huggingface.co/datasets/Benchanything/checkerbench/resolve/main/tasks/codeql_java_benchmark_top30_v2/morefixes-04bdb708bf23aabdc444/patch.diff
2.15 kB
| diff --git a/src/main/java/au/com/rayh/XcodeProjectParser.java b/src/main/java/au/com/rayh/XcodeProjectParser.java | |
| index 09db4c8..e05177e 100644 | |
| --- a/src/main/java/au/com/rayh/XcodeProjectParser.java | |
| +++ b/src/main/java/au/com/rayh/XcodeProjectParser.java | |
| public class XcodeProjectParser { | |
| ProjectScheme projectScheme = new ProjectScheme(); | |
| try { | |
| DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); | |
| + | |
| + String FEATURE = null; | |
| + FEATURE = "http://apache.org/xml/features/disallow-doctype-decl"; | |
| + factory.setFeature(FEATURE, true); | |
| + FEATURE = "http://xml.org/sax/features/external-general-entities"; | |
| + factory.setFeature(FEATURE, false); | |
| + FEATURE = "http://xml.org/sax/features/external-parameter-entities"; | |
| + factory.setFeature(FEATURE, false); | |
| + FEATURE = "http://apache.org/xml/features/nonvalidating/load-external-dtd"; | |
| + factory.setFeature(FEATURE, false); | |
| + factory.setXIncludeAware(false); | |
| + factory.setExpandEntityReferences(false); | |
| + | |
| DocumentBuilder documentBuilder = factory.newDocumentBuilder(); | |
| Document document = documentBuilder.parse(schemeFile.read()); | |
| public class XcodeProjectParser { | |
| try { | |
| FilePath workspaceFilePath = workspaceFileLocation.child("contents.xcworkspacedata"); | |
| DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); | |
| + | |
| + String FEATURE = null; | |
| + FEATURE = "http://apache.org/xml/features/disallow-doctype-decl"; | |
| + factory.setFeature(FEATURE, true); | |
| + FEATURE = "http://xml.org/sax/features/external-general-entities"; | |
| + factory.setFeature(FEATURE, false); | |
| + FEATURE = "http://xml.org/sax/features/external-parameter-entities"; | |
| + factory.setFeature(FEATURE, false); | |
| + FEATURE = "http://apache.org/xml/features/nonvalidating/load-external-dtd"; | |
| + factory.setFeature(FEATURE, false); | |
| + factory.setXIncludeAware(false); | |
| + factory.setExpandEntityReferences(false); | |
| + | |
| DocumentBuilder documentBuilder = factory.newDocumentBuilder(); | |
| Document document = documentBuilder.parse(workspaceFilePath.read()); | |