gzip: flush output buffer after stored blocks only if necessary
function old new delta flush_block 671 680 +9 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
parent
f21ebeece5
commit
919bc9d43c
@ -634,6 +634,7 @@ static void copy_block(char *buf, unsigned len, int header)
|
|||||||
put_8bit(*buf++);
|
put_8bit(*buf++);
|
||||||
}
|
}
|
||||||
/* The above can 32-bit misalign outbuf */
|
/* The above can 32-bit misalign outbuf */
|
||||||
|
if (G1.outcnt & 3) /* syscalls are expensive, is it really misaligned? */
|
||||||
flush_outbuf_if_32bit_optimized();
|
flush_outbuf_if_32bit_optimized();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user