[
https://issues.apache.org/jira/browse/TIKA-3308?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17635997#comment-17635997
]
Hudson commented on TIKA-3308:
------------------------------
SUCCESS: Integrated in Jenkins build Tika » tika-main-jdk8 #930 (See
[https://ci-builds.apache.org/job/Tika/job/tika-main-jdk8/930/])
TIKA-3308 -- add detection for svg files that lack the xml header (#808)
(github:
[https://github.com/apache/tika/commit/0145868ab5c1f2718dc3267e50737d22effb3ce6])
* (add)
tika-parsers/tika-parsers-standard/tika-parsers-standard-modules/tika-parser-pkg-module/src/test/resources/test-documents/testSVG_no_xml_header.svg
* (edit) tika-core/src/main/resources/org/apache/tika/mime/tika-mimetypes.xml
* (edit)
tika-parsers/tika-parsers-standard/tika-parsers-standard-package/src/test/java/org/apache/tika/mime/TestMimeTypes.java
* (edit) CHANGES.txt
> SVG file without xml declaration tag is detected as text/plain
> --------------------------------------------------------------
>
> Key: TIKA-3308
> URL: https://issues.apache.org/jira/browse/TIKA-3308
> Project: Tika
> Issue Type: Bug
> Components: mime
> Affects Versions: 1.25
> Reporter: Anas Hammani
> Priority: Minor
> Fix For: 2.6.1
>
> Attachments: logo-luma.svg
>
>
> The SVG file attached to the issue is interpreted as *text/plain* by
> {code:java}
> tika.detect(filePath){code}
>
> If I add
> {code:java}
> <?xml version="1.0" standalone="no"?> {code}
> at the beginning of the file, then tika detects it as "image/svg+xml"
>
> When i read the documentation i see that xml is not necessary for a file to
> be well-formed
> [https://www.w3.org/TR/REC-xml/#sec-prolog-dtd]
>
> It will be great if tika can detect a file as a SVG without the prolog
>
--
This message was sent by Atlassian Jira
(v8.20.10#820010)