From owner-freebsd-current@FreeBSD.ORG Thu Jul 22 07:19:38 2004 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3A63616A4CE; Thu, 22 Jul 2004 07:19:38 +0000 (GMT) Received: from nagual.pp.ru (pobrecita.freebsd.ru [194.87.13.42]) by mx1.FreeBSD.org (Postfix) with ESMTP id 689C243D48; Thu, 22 Jul 2004 07:19:37 +0000 (GMT) (envelope-from ache@pobrecita.freebsd.ru) Received: from pobrecita.freebsd.ru (ache@localhost [127.0.0.1]) by nagual.pp.ru (8.12.11/8.12.11) with ESMTP id i6M7JTYo013665; Thu, 22 Jul 2004 11:19:29 +0400 (MSD) (envelope-from ache@pobrecita.freebsd.ru) Received: (from ache@localhost) by pobrecita.freebsd.ru (8.12.11/8.12.11/Submit) id i6M7JTxi013664; Thu, 22 Jul 2004 11:19:29 +0400 (MSD) (envelope-from ache) Date: Thu, 22 Jul 2004 11:19:29 +0400 From: Andrey Chernov To: Tim Kientzle Message-ID: <20040722071929.GA13591@nagual.pp.ru> Mail-Followup-To: Andrey Chernov , Tim Kientzle , Tim Kientzle , current@FreeBSD.ORG, ports@FreeBSD.ORG References: <40F963D8.6010201@freebsd.org> <20040719060730.GA87697@nagual.pp.ru> <40FC9FC2.8050400@kientzle.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <40FC9FC2.8050400@kientzle.com> User-Agent: Mutt/1.5.6i X-AntiVirus: checked by AntiVir Milter 1.1-beta; AVE 6.26.0.8; VDF 6.26.0.37 (host: pobrecita.freebsd.ru) cc: ports@FreeBSD.ORG cc: Tim Kientzle cc: current@FreeBSD.ORG Subject: Re: NEW TAR X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 22 Jul 2004 07:19:38 -0000 On Mon, Jul 19, 2004 at 09:29:54PM -0700, Tim Kientzle wrote: > but they're not gtar-compatible. (The gtar > approach has a number of drawbacks. The primary > one being that on many systems it requires reading > the entire file twice, once to find holes and again > to actually archive the file. It is possible to > do both in one pass if you store the sparse file > data in a different fashion.) I can't imagine the case when 2 passes are needed. Even if you have normal file in the archive and specify -S only when extracting (it should work as expected), only 1 pass is needed. Just stop on first '\0' and count them until they finished, then do lseek (real case will be a bit harder to implement because of block boundaries). -- Andrey Chernov | http://ache.pp.ru/