Uploaded image for project: 'Maven Javadoc Plugin'
  1. Maven Javadoc Plugin
  2. MJAVADOC-469

<additionalOption> input isn't escaped for double backslashes in argument file

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.10.4
    • Fix Version/s: 3.1.0
    • Component/s: javadoc
    • Labels:
      None

      Description

      On Windows `generate-rest-docs` goal of `maven-jira-plugin` calls `maven-javadoc-plugin` with:

      additionalparam: -output "C:\path\to\target\classes\resourcedoc.xml"

      If this argument was passed to `javadoc.exe` directly, I'm pretty sure this would work. However, the javadoc plugin generates an argument file[1] named "options" and executes:

      javadoc.exe ... @options

      The file contains all arguments with unescaped backslashes, although javadoc command documentation[2] suggests:

      If a filename contains embedded spaces, put the whole filename in double quotes, and double each backslash ("My Files
      Stuff.java")

      javadoc plugin version "2.4" is hardcoded in jira plugin, but I see no related changes in "2.10.4" in AbstractJavadocMojo.addCommandLineOptions() .

      [1]: https://maven.apache.org/plugins/maven-javadoc-plugin/
      [2]: http://docs.oracle.com/javase/7/docs/technotes/tools/windows/javadoc.html#argumentfiles

        Attachments

          Activity

            People

            • Assignee:
              michael-o Michael Osipov
              Reporter:
              basinilya Ilya Basin
            • Votes:
              1 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: