gunzip: the extra length field (XLEN) is two bytes instead of one
example file: https://www.mirbsd.org/MirOS/dist/mir/mksh/mksh-R50f.tgz
This commit is contained in:
parent
20b8f1e777
commit
0d701b7759
1 changed files with 5 additions and 2 deletions
|
@ -236,9 +236,12 @@ header(Biobuf *bin, GZHead *h)
|
|||
/* OS type */
|
||||
get1(bin);
|
||||
|
||||
if(flag & GZFEXTRA)
|
||||
for(i=get1(bin); i>0; i--)
|
||||
if(flag & GZFEXTRA){
|
||||
i = get1(bin);
|
||||
i |= get1(bin)<<8;
|
||||
for(; i>0; i--)
|
||||
get1(bin);
|
||||
}
|
||||
|
||||
/* name */
|
||||
if(flag & GZFNAME){
|
||||
|
|
Loading…
Reference in a new issue