From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1MKrYI-0004U1-R3 for mharc-grub-devel@gnu.org; Sun, 28 Jun 2009 06:24:02 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MKrYF-0004T8-Us for grub-devel@gnu.org; Sun, 28 Jun 2009 06:24:00 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MKrYB-0004Ri-6l for grub-devel@gnu.org; Sun, 28 Jun 2009 06:23:59 -0400 Received: from [199.232.76.173] (port=46286 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MKrYA-0004Ra-TV for grub-devel@gnu.org; Sun, 28 Jun 2009 06:23:54 -0400 Received: from moutng.kundenserver.de ([212.227.126.171]:53341) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MKrYA-0002gE-1O for grub-devel@gnu.org; Sun, 28 Jun 2009 06:23:54 -0400 Received: from [85.180.45.130] (e180045130.adsl.alicedsl.de [85.180.45.130]) by mrelayeu.kundenserver.de (node=mreu2) with ESMTP (Nemesis) id 0MKv5w-1MKrXt1SEP-000LKd; Sun, 28 Jun 2009 12:23:37 +0200 From: Felix Zielcke To: Robert Millan In-Reply-To: <20090620134351.GA22660@thorin> References: <20090620134351.GA22660@thorin> Content-Type: text/plain Date: Sun, 28 Jun 2009 12:23:36 +0200 Message-Id: <1246184616.3478.1.camel@fz.local> Mime-Version: 1.0 X-Mailer: Evolution 2.26.2 Content-Transfer-Encoding: 7bit X-Provags-ID: V01U2FsdGVkX18FT/6YYDXEYXlfT3CDPumdPqrO9Ji8zcYwZ+Q FVg+WjFVHv8B56u/++Ba2ZwNdWGNSikpg5OSWmJ2uS+qOIhODb JYoJOXuKPnqvcTDE6u2vQ== X-detected-operating-system: by monty-python.gnu.org: Genre and OS details not recognized. Cc: grub-devel@gnu.org Subject: Re: [2338] 2009-06-17 Felix Zielcke 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: Sun, 28 Jun 2009 10:24:00 -0000 Am Samstag, den 20.06.2009, 15:43 +0200 schrieb Robert Millan: > Hi Felix, > > This commit looks wrong. grub_file_open is already supposed to set > grub_errno and grub_errmsg appropiately. > > Is there a specific problem you wanted to fix here? If the loaded file can't be found, the menuentry code just continuesa and initrd then complains that you must load the kernel first. > On Wed, Jun 17, 2009 at 05:19:23PM +0000, Felix Zielcke wrote: > > Revision: 2338 > > http://svn.sv.gnu.org/viewvc/?view=rev&root=grub&revision=2338 > > Author: fzielcke > > Date: 2009-06-17 17:19:23 +0000 (Wed, 17 Jun 2009) > > Log Message: > > ----------- > > 2009-06-17 Felix Zielcke > > > > * loader/i386/linux.c (grub_cmd_linux): Set grub_error if the > > file can't be found. > > * loader/i386/pc/linux.c (grub_cmd_linux): Likewise. > > > > Modified Paths: > > -------------- > > trunk/grub2/ChangeLog > > trunk/grub2/loader/i386/linux.c > > trunk/grub2/loader/i386/pc/linux.c > > > > Modified: trunk/grub2/ChangeLog > > =================================================================== > > --- trunk/grub2/ChangeLog 2009-06-17 13:47:37 UTC (rev 2337) > > +++ trunk/grub2/ChangeLog 2009-06-17 17:19:23 UTC (rev 2338) > > @@ -1,3 +1,9 @@ > > +2009-06-17 Felix Zielcke > > + > > + * loader/i386/linux.c (grub_cmd_linux): Set grub_error if the > > + file can't be found. > > + * loader/i386/pc/linux.c (grub_cmd_linux): Likewise. > > + > > 2009-06-17 Vladimir Serbinenko > > > > Fix newline handling > > > > Modified: trunk/grub2/loader/i386/linux.c > > =================================================================== > > --- trunk/grub2/loader/i386/linux.c 2009-06-17 13:47:37 UTC (rev 2337) > > +++ trunk/grub2/loader/i386/linux.c 2009-06-17 17:19:23 UTC (rev 2338) > > @@ -600,7 +600,10 @@ > > > > file = grub_file_open (argv[0]); > > if (! file) > > - goto fail; > > + { > > + grub_error (GRUB_ERR_FILE_NOT_FOUND, "file not found"); > > + goto fail; > > + } > > > > if (grub_file_read (file, &lh, sizeof (lh)) != sizeof (lh)) > > { > > > > Modified: trunk/grub2/loader/i386/pc/linux.c > > =================================================================== > > --- trunk/grub2/loader/i386/pc/linux.c 2009-06-17 13:47:37 UTC (rev 2337) > > +++ trunk/grub2/loader/i386/pc/linux.c 2009-06-17 17:19:23 UTC (rev 2338) > > @@ -69,7 +69,10 @@ > > > > file = grub_file_open (argv[0]); > > if (! file) > > - goto fail; > > + { > > + grub_error (GRUB_ERR_FILE_NOT_FOUND, "file not found"); > > + goto fail; > > + } > > > > if ((grub_size_t) grub_file_size (file) > grub_os_area_size) > > { > > > > > > > > > -- Felix Zielcke