Sebastian Reichel 0deb096ea7 Fix magic files (#6178)
* magic: fix 'Printf format is too long' warnings

* magic: fix warning: Current entry does not yet have a description for adding a MIME type

* magic: fix mime type for debian packages

* magic: workaround for libmagic bug

libmagic currently warns about beshort/leshort type being
printed as "%hd" with the following warning:

Printf format is too long for type `leshort' in description `%hd'

As a workaround the short value can be printed using '%d'
without generating a warning.
2016-11-12 11:10:09 +01:00
..
2016-11-12 11:10:09 +01:00

This implementation of file(1) has been taken from OpenBSD,
I have removed the elf part which reduces more than 1KLOC.
I have also cleaned up the code in order to fix some warnings
and integrate with r2 syntax. magic_ api is now r_magic_

   --pancake

$ cvs -d anoncvs@anoncvs.ca.openbsd.org:/cvs get src/usr.bin/file

* understand and document how conditional works