Arch Linux

Please read this before reporting a bug:

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!

FS#71130 - [file] file -mime misdetects cpio files

Attached to Project: Arch Linux
Opened by Emil (xexaxo) - Friday, 04 June 2021, 20:39 GMT
Last edited by Sébastien Luttringer (seblu) - Tuesday, 19 October 2021, 00:27 GMT
Task Type Bug Report
Category Packages: Core
Status Closed
Assigned To Sébastien Luttringer (seblu)
Architecture All
Severity Medium
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No



`file -mime foo.cpio` incorrectly detects the file as octet-stream.
`file foo.cpio` seem smarter.

Notices while hacking on mkinitcpio.

Additional info:
* package version(s)

* link to upstream bug report, if any

Steps to reproduce:

echo test > test-file
LANG=C bsdtar --uid 0 --gid 0 --null -cf - --format=newc test-file > foo.cpio
file --mime foo.cpio
foo.cpio: application/octet-stream; charset=binary <<< WRONG
file foo.cpio
foo.cpio: ASCII cpio archive (SVR4 with no CRC) <<< GOOD
This task depends upon

Closed by  Sébastien Luttringer (seblu)
Tuesday, 19 October 2021, 00:27 GMT
Reason for closing:  Fixed
Additional comments about closing:  fixed in 5.41
Comment by Emil (xexaxo) - Friday, 09 July 2021, 11:50 GMT
Note: different (also working) version was merged upstream