Assuming "text/plain" for text-like MIME sniffing buffers often leads to problems

When no MIME type is found to match for the contents sniff of a file and
the buffer looks like text, "text/plain" is assumed. When the
subclassing information isn't correct (for instance, the current
shared-mime-info release 0.17 doesn't have "text/plain" =>
"application/pdf" associations), this will make the contents sniff take
precedence over the extension and for instance evince can't handle the
file, and  Nautilus will bail when activating the file.
I therefore propose to always return XDG_MIME_TYPE_UNKNOWN if the result
can't be determined.

I've done lots of work on shared-mime-info but my home-brewn xml parser
tells me that there are 430 MIME types that have no subclassing
information and I'm not inclined to spend a few dozen hours on this
package, ensuring that all text MIME types are subclasses of

Christian Neumair <chris gnome-de org>

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]