Bug 22634 - files named "Core" but with text content are incorrectly recognized as mimetype "application/x-core"
Summary: files named "Core" but with text content are incorrectly recognized as mimety...
Status: RESOLVED FIXED
Alias: None
Product: shared-mime-info
Classification: Unclassified
Component: general (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: Jonathan Blandford
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-07-06 08:45 UTC by Andreas Pakulat
Modified: 2009-10-06 04:41 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments

Description Andreas Pakulat 2009-07-06 08:45:11 UTC
The current glob-rule for any files named "core" to be recognized as "application/x-core" creates problems for text files named "Core" or "CoreFoo". This is particularly bad as C++ headers these days are often named without file extension. 

Not sure how to best fix this, basically a combination of "name==core" and "magic that detects 'ELF' at the start of the file" would be needed...
Comment 1 David Faure 2009-08-18 06:38:35 UTC
Proposed solution sent to the xdg list: case-sensitive="true".
Comment 2 Bastien Nocera 2009-10-06 04:41:48 UTC
Fixed in recent xdgmime and shared-mime-info. I added a test case for those in the repo.

* tests/list: Add test case for core vs. Core files
(Closes: #22634)


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.