Red Hat Bugzilla – Bug 106550
"file -z" hangs on examining some gzipped files
Last modified: 2007-11-30 17:10:32 EST
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.4)
Gecko/20030624 Netscape/7.1 (ax)
Description of problem:
file command hangs on examining some compressed files with the "-z" option.
on my system:
$ ls -l /usr/bin > lsl
$ gzip lzl
$ file lzl.gz # this works
$ fils -z lsl.gz # this hangs
"file -z" seems to work on short files, but inexplicably hangs on the above.
(at least, after 20 seconds, i feel it's safe to kill it.)
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. ls -l /usr/bin > lsl
2. gzip lsl
3. file -z lsl.gz
Probably a dup of bug 106424 - does upgrading zlib fix it?
No, zlib-220.127.116.11-2 upgrade does not fix.
strace indicates gzip exec and probable child-before-parent problem.
Hmmm, HAVE_LIBZ is deliberately undef'd, dunno.
Off to look at file-4.04.
Yup, nuking the line
in src/compress.c restores file -z functionality.
child-before-parent problem prolly still exists however.
FIxed in file-4.06-1.