From owner-svn-src-all@FreeBSD.ORG Thu Jan 1 02:29:57 2009 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5FE9F1065670; Thu, 1 Jan 2009 02:29:57 +0000 (UTC) (envelope-from kientzle@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4E0AD8FC25; Thu, 1 Jan 2009 02:29:57 +0000 (UTC) (envelope-from kientzle@FreeBSD.org) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id n012TvkJ041729; Thu, 1 Jan 2009 02:29:57 GMT (envelope-from kientzle@svn.freebsd.org) Received: (from kientzle@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id n012TvPk041728; Thu, 1 Jan 2009 02:29:57 GMT (envelope-from kientzle@svn.freebsd.org) Message-Id: <200901010229.n012TvPk041728@svn.freebsd.org> From: Tim Kientzle Date: Thu, 1 Jan 2009 02:29:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r186670 - head/lib/libarchive X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 01 Jan 2009 02:29:58 -0000 Author: kientzle Date: Thu Jan 1 02:29:57 2009 New Revision: 186670 URL: http://svn.freebsd.org/changeset/base/186670 Log: Don't try to read the next Gzip header after we reach the end of the compressed stream. This is desirable behavior, but the implementation here is very broken and causes strange problems, so disable it for now. Thanks to Simon L. Nielsen for reporting this problem. Modified: head/lib/libarchive/archive_read_support_compression_gzip.c Modified: head/lib/libarchive/archive_read_support_compression_gzip.c ============================================================================== --- head/lib/libarchive/archive_read_support_compression_gzip.c Thu Jan 1 02:29:17 2009 (r186669) +++ head/lib/libarchive/archive_read_support_compression_gzip.c Thu Jan 1 02:29:57 2009 (r186670) @@ -428,8 +428,9 @@ gzip_source_read(struct archive_read_sou "Failed to clean up gzip decompressor"); return (ARCHIVE_FATAL); } - /* Restart header parser with the next block. */ - state->header_state = state->header_done = 0; + /* zlib has been torn down */ + state->header_done = 0; + state->eof = 1; /* FALL THROUGH */ case Z_OK: /* Decompressor made some progress. */ /* If we filled our buffer, update stats and return. */