diff --git a/tools/java-source-utils/src/main/java/com/microsoft/android/JavaSourceUtilsOptions.java b/tools/java-source-utils/src/main/java/com/microsoft/android/JavaSourceUtilsOptions.java index 6a453d669..f110c170d 100644 --- a/tools/java-source-utils/src/main/java/com/microsoft/android/JavaSourceUtilsOptions.java +++ b/tools/java-source-utils/src/main/java/com/microsoft/android/JavaSourceUtilsOptions.java @@ -167,7 +167,7 @@ private final JavaSourceUtilsOptions parse(Iterator args) throws IOExcep final String bootClassPath = getNextOptionValue(args, arg); final ArrayList files = new ArrayList(); for (final String cp : bootClassPath.split(File.pathSeparator)) { - final File file = new File(cp); // lgtm [java/path-injection-local] + final File file = new File(cp); // lgtm [java/path-injection-local] java-source-utils.jar is a command-line app, and is useless if it doesn't support command-line args. if (!file.exists()) { System.err.println(App.APP_NAME + ": warning: invalid file path for option `-bootclasspath`: " + cp); continue; @@ -253,7 +253,7 @@ private final JavaSourceUtilsOptions parse(Iterator args) throws IOExcep if (arg.startsWith("@")) { // response file? final String responseFileName = arg.substring(1); - final File responseFile = new File(responseFileName); // lgtm [java/path-injection-local] + final File responseFile = new File(responseFileName); // lgtm [java/path-injection-local] java-source-utils.jar is a command-line app, and is useless if it doesn't support command-line args. if (responseFile.exists()) { final Iterator lines = Files.readAllLines(responseFile.toPath()) @@ -267,7 +267,7 @@ private final JavaSourceUtilsOptions parse(Iterator args) throws IOExcep break; } } - final File file = new File(arg); // lgtm [java/path-injection-local] + final File file = new File(arg); // lgtm [java/path-injection-local] java-source-utils.jar is a command-line app, and is useless if it doesn't support command-line args. if (!file.exists()) { System.err.println(App.APP_NAME + ": warning: invalid file path for option `FILES`: " + arg); break; @@ -347,7 +347,7 @@ static File getNextOptionFile(final Iterator args, final String option) throw new IllegalArgumentException( "Expected required value for option `" + option + "`."); final String fileName = args.next(); - final File file = new File(fileName); // lgtm [java/path-injection-local] + final File file = new File(fileName); // lgtm [java/path-injection-local] java-source-utils.jar is a command-line app, and is useless if it doesn't support command-line args. if (!file.exists()) { System.err.println(App.APP_NAME + ": warning: invalid file path for option `" + option + "`: " + fileName); return null; diff --git a/tools/java-source-utils/src/main/java/com/microsoft/android/JavadocXmlGenerator.java b/tools/java-source-utils/src/main/java/com/microsoft/android/JavadocXmlGenerator.java index 21f3f6251..ba1246819 100644 --- a/tools/java-source-utils/src/main/java/com/microsoft/android/JavadocXmlGenerator.java +++ b/tools/java-source-utils/src/main/java/com/microsoft/android/JavadocXmlGenerator.java @@ -39,7 +39,7 @@ public JavadocXmlGenerator(final String output) throws FileNotFoundException, Pa if (output == null) this.output = System.out; else { - final File file = new File(output); // lgtm [java/path-injection-local] + final File file = new File(output); // lgtm [java/path-injection-local] java-source-utils.jar is a command-line app, and is useless if it doesn't support command-line args. final File parent = file.getParentFile(); if (parent != null) { parent.mkdirs();