qpdfview does not open a file
Bug #1577501 reported by
Thibaud
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
qpdfview |
Invalid
|
Undecided
|
Unassigned |
Bug Description
Step to reproduce:
1) Open the attached file with qpdfview
2) qpdfview show the message "could not open" (in command line, it says "Unknown file type: application/
3) open the attached file with Evince: the file is displayed correctly.
To post a comment you must log in.
Hello Thibaud,
thank you for taking the time to report this. Depending on the build environment, qpdfview will use Qt's built-in MIME type detection (based on the FDo shared MIME info database [1]) or uses libmagic to determine the file type. For the attached document, the file command (i.e. libmagic) will indeed report
> file --mime-type 424963.pdf octet-stream
424963.pdf: application/
which seems to be related to some amount of garbage at the beginning of the document, e.g.
> pdf2ps 424963.pdf
**** Warning: File has some garbage before %PDF- .
> ps2pdf 424963.ps
> file --mime-type 424963.pdf
424963.pdf: application/pdf
will fix this and qpdfview will open the document.
[1] https:/ /freedesktop. org/wiki/ Software/ shared- mime-info/