Red Hat Bugzilla – Bug 147440
[PATCH] file -z bugs when checking bzip2 files.
Last modified: 2007-11-30 17:10:59 EST
gzip -c badseed-linux-devolutionwm1-0.png >
bzip2 -c badseed-linux-devolutionwm1-0.png >
compress -c badseed-linux-devolutionwm1-0.png >
file -zi *
badseed-linux-devolutionwm1-0.png.gz: image/png (application/x-gzip)
badseed-linux-devolutionwm1-0.png.Z: image/png (application/x-compress)
It should be:
badseed-linux-devolutionwm1-0.png.bz2: image/png (application/x-bzip2)
file -z bison-1.29.tar.bz2
You will get:
bison-1.29.tar.bz2: bison-1.29.tar.bz2: bzip2 compressed data, block
size = 900k
bison-1.29.tar.bz2 - is replayed twice, shoud only be one
The second bug can be resolved by adding:
The first bug can be resolved by attached patch (it also fixes the
first one). I've recived it from Christos Zoulas (file developer).
But beware that this patch has enabled debuging.
Created attachment 110762 [details]
Patch to fix bugs described in bug report.
There is also one more bug:
1) wget http://search.cpan.org/src/GAAS/Image-Info-1.16/img/test.xpm
2) file -iz test.xpm
011 is a â\tâ char and shouldn't be displayed (tab should be inserted).
This bug is known and fixed by Christos, but I didn't recived patch
for this, should I mail him for it?
I've tested above bugs on file-4.12-3. Attached patch will apply if
you disable file-4.12-compress.patch
Patch looks good, thx. Just I've kept the compress patch with two pids
solving the fork() problem rather than yours. I've emailed Christos
about the second bug and hopefully will get the patch from him.
file-4.13 has been released on 2005-02-09.
file-4.13 is now in devel branch