git: 9front

Download patch

ref: f8e042d44798d34e1512f3cf3b4c4bb3f09cb4af
parent: 9ea6e43cf3ee24fc942221a6e48f32c7f08ec868
author: cinap_lenrek <cinap_lenrek@felloff.net>
date: Sun Aug 27 14:44:04 EDT 2023

bzip2: use IOUNIT for transfer block size

--- a/sys/src/cmd/bzip2/bunzip2.c
+++ b/sys/src/cmd/bzip2/bunzip2.c
@@ -125,8 +125,8 @@
 bunzip(int ofd, char *ofile, Biobuf *bin)
 {
 	int e, n, done, onemore;
-	char buf[8192];
-	char obuf[8192];
+	char buf[IOUNIT];
+	char obuf[IOUNIT];
 	Biobuf bout;
 	bz_stream strm;
 
--- a/sys/src/cmd/bzip2/bzip2.c
+++ b/sys/src/cmd/bzip2/bzip2.c
@@ -132,8 +132,8 @@
 bzip(char *file, long mtime, int ifd, Biobuf *bout)
 {
 	int e, n, done, onemore;
-	char buf[8192];
-	char obuf[8192];
+	char buf[IOUNIT];
+	char obuf[IOUNIT];
 	Biobuf bin;
 	bz_stream strm;
 
--