Commons Digester
  1. Commons Digester
  2. DIGESTER-35

Digester.parse(File) is crippled in two aspects

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: Nightly Builds
    • Fix Version/s: None
    • Labels:
      None
    • Environment:

      Operating System: All
      Platform: All

      Description

      1. It constructs an InputSource with a Reader instead of with an InputStream,
      thus effectively forcing the XML parser to interpret the XML file as it is
      written in default platform encoding instead of honoring eventual <?xml
      encoding="..."?> declarations.

      2. It does not set the system id of the input source to "file://" +
      file.getAbsolutePath(), therefore making it impossible to resolve external
      entities referenced by relative URLs in the XML file.

      A patch is attached that fixes both problems.

        Activity

        Attila Szegedi created issue -
        Hide
        Attila Szegedi added a comment -

        Created an attachment (id=1682)
        Patch that fixes both problems

        Show
        Attila Szegedi added a comment - Created an attachment (id=1682) Patch that fixes both problems
        Hide
        Craig McClanahan added a comment -

        Fixed in nightly build 20020428. Thanks for the patch!

        Show
        Craig McClanahan added a comment - Fixed in nightly build 20020428. Thanks for the patch!
        Henri Yandell made changes -
        Field Original Value New Value
        issue.field.bugzillaimportkey 8461 12340208
        Henri Yandell made changes -
        Affects Version/s Nightly Builds [ 12311648 ]
        Component/s Digester [ 12311111 ]
        Project Commons [ 12310458 ] Commons Digester [ 12310471 ]
        Assignee Jakarta Commons Developers Mailing List [ commons-dev@jakarta.apache.org ]
        Key COM-57 DIGESTER-35
        Henri Yandell made changes -
        Affects Version/s Nightly Builds [ 12311810 ]
        Henri Yandell made changes -
        Status Resolved [ 5 ] Closed [ 6 ]

          People

          • Assignee:
            Unassigned
            Reporter:
            Attila Szegedi
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development