Bug 26571 - magic for hdf files
Summary: magic for hdf files
Status: RESOLVED FIXED
Alias: None
Product: shared-mime-info
Classification: Unclassified
Component: freedesktop.org.xml (show other bugs)
Version: unspecified
Hardware: All All
: medium normal
Assignee: Jonathan Blandford
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-02-14 22:39 UTC by Achim Gaedke
Modified: 2010-02-16 02:05 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
hdf magic numbers (3.10 KB, patch)
2010-02-16 01:56 UTC, Achim Gaedke
Details | Splinter Review

Description Achim Gaedke 2010-02-14 22:39:23 UTC
Hi there!

Could you please add these file signatures to application/x-hdf?

<magic>
    <!--see: HDF5 File Format Specification Version 2.0 Chapter II -->
    <match type="string" offset="0" value="\211HDF\r\n\032\n"/>
    <!--see: HDF4r15_SpecDG.pdf Chapter 2.2: 0x0E 0x03 0x13 0x01 -->
    <match type="string" offset="0" value="\016\003\023\001"/>
</magic>

and add the name patterns:

    <glob pattern="*.h4" />
    <glob pattern="*.hdf4" />
    <glob pattern="*.h5" />
    <glob pattern="*.hdf5" />

which were suggested by the hdfgroup's own data browser hdfview. All that covers two versions of the hdf standard.

Achim
Comment 1 Bastien Nocera 2010-02-15 02:57:27 UTC
Please read the HACKING file and provide an updated patch.
Comment 2 Achim Gaedke 2010-02-16 01:56:24 UTC
Created attachment 33326 [details] [review]
hdf magic numbers

magic numbers for hierarchical data file format, reference:
* HDF5 File Format Specification Version 2.0 Chapter II
* HDF4r15_SpecDG.pdf Chapter 2.2: 0x0E 0x03 0x13 0x01
test files created with hdfview
Comment 3 Bastien Nocera 2010-02-16 02:05:13 UTC
commit ef12958c9cadebdfaea5fb45dfa1615fc279f6c6
Author: Achim Gaedke <Achim.Gaedke@vuw.ac.nz>
Date:   Tue Feb 16 22:52:00 2010 +1300

    Add magic for hierarchical data file format (HDF)
    
    * HDF5 File Format Specification Version 2.0 Chapter II
    * HDF4r15_SpecDG.pdf Chapter 2.2: 0x0E 0x03 0x13 0x01
    
    test files created with hdfview
    
    http://bugs.freedesktop.org/show_bug.cgi?id=26571


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.