From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1JH8Ru-0005Je-Ii for mharc-grub-devel@gnu.org; Mon, 21 Jan 2008 21:01:14 -0500 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JH8Rt-0005JJ-Gc for grub-devel@gnu.org; Mon, 21 Jan 2008 21:01:13 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JH8Rr-0005J6-42 for grub-devel@gnu.org; Mon, 21 Jan 2008 21:01:12 -0500 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JH8Rq-0005Ix-Tf for grub-devel@gnu.org; Mon, 21 Jan 2008 21:01:10 -0500 Received: from c60.cesmail.net ([216.154.195.49]) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_ARCFOUR_SHA1:16) (Exim 4.60) (envelope-from ) id 1JH8Rq-000541-GK for grub-devel@gnu.org; Mon, 21 Jan 2008 21:01:10 -0500 Received: from unknown (HELO relay.cesmail.net) ([192.168.1.81]) by c60.cesmail.net with ESMTP; 21 Jan 2008 21:01:09 -0500 Received: from [192.168.1.21] (static-72-92-88-10.phlapa.fios.verizon.net [72.92.88.10]) by relay.cesmail.net (Postfix) with ESMTP id 98404618FE1 for ; Mon, 21 Jan 2008 21:01:08 -0500 (EST) From: Pavel Roskin To: The development of GRUB 2 In-Reply-To: <20080121210903.GD15119@thorin> References: <20080121165209.GA2557@thorin> <1200937626.4686.17.camel@dv> <20080121210903.GD15119@thorin> Content-Type: text/plain Date: Mon, 21 Jan 2008 21:01:07 -0500 Message-Id: <1200967267.32578.40.camel@dv> Mime-Version: 1.0 X-Mailer: Evolution 2.12.2 (2.12.2-3.fc8) Content-Transfer-Encoding: 7bit X-detected-kernel: by monty-python.gnu.org: Genre and OS details not recognized. Subject: Re: grub_cpio_find_file() finds unexisting files (Re: [PATCH] memdisk + grub-mkrescue) X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: The development of GRUB 2 List-Id: The development of GRUB 2 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2008 02:01:13 -0000 On Mon, 2008-01-21 at 22:09 +0100, Robert Millan wrote: > On Mon, Jan 21, 2008 at 12:47:06PM -0500, Pavel Roskin wrote: > > > > I've tested the patch, and it seems to be OK, although I was surprised > > to see an empty menu on startup. Perhaps a command line would be more > > appropriate in absence of grub.cfg? > > I wanted to send a new mail about this, and then forgot. > > This is because of a bug in cpio.mod. The menu code thinks grub.cfg is > present due to grub_cpio_find_file() returning here: > > if (!hd.name[0]) > { > *ofs = 0; > return GRUB_ERR_NONE; > } > > but I'm too clueless about tar format to figure this out. I guess the meaning of GRUB_ERR_NONE is confusing (no file vs. no error), and the return value of grub_cpio_find_file() is not well defined. Perhaps it should be GRUB_ERR_FILE_NOT_FOUND instead. -- Regards, Pavel Roskin