svn commit: r268516 - stable/10/usr.bin/gzip

Xin LI delphij at FreeBSD.org
Fri Jul 11 00:08:13 UTC 2014


Author: delphij
Date: Fri Jul 11 00:08:13 2014
New Revision: 268516
URL: http://svnweb.freebsd.org/changeset/base/268516

Log:
  MFC r267887:
  
  Correct buffer size.
  
  Submitted by:	Sascha Wildner <swildner dragonflybsd org>

Modified:
  stable/10/usr.bin/gzip/zuncompress.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/usr.bin/gzip/zuncompress.c
==============================================================================
--- stable/10/usr.bin/gzip/zuncompress.c	Fri Jul 11 00:00:00 2014	(r268515)
+++ stable/10/usr.bin/gzip/zuncompress.c	Fri Jul 11 00:08:13 2014	(r268516)
@@ -145,7 +145,7 @@ zuncompress(FILE *in, FILE *out, char *p
 	else
 		compressed_pre = NULL;
 
-	while ((bin = fread(buf, 1, sizeof(buf), in)) != 0) {
+	while ((bin = fread(buf, 1, BUFSIZE, in)) != 0) {
 		if (tflag == 0 && (off_t)fwrite(buf, 1, bin, out) != bin) {
 			free(buf);
 			return -1;


More information about the svn-src-all mailing list