Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1MUcl2-0004rC-IR for mharc-grub-devel@gnu.org; Sat, 25 Jul 2009 04:37:32 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MUcl1-0004py-2J for grub-devel@gnu.org; Sat, 25 Jul 2009 04:37:31 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MUckv-0004ml-Q4 for grub-devel@gnu.org; Sat, 25 Jul 2009 04:37:30 -0400 Received: from [199.232.76.173] (port=43581 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MUckv-0004md-Kb for grub-devel@gnu.org; Sat, 25 Jul 2009 04:37:25 -0400 Received: from mail-fx0-f216.google.com ([209.85.220.216]:38086) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MUckv-00064O-AU for grub-devel@gnu.org; Sat, 25 Jul 2009 04:37:25 -0400 Received: by fxm12 with SMTP id 12so1360878fxm.42 for ; Sat, 25 Jul 2009 01:37:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type :content-transfer-encoding; bh=4ZKPynMXYj3Q95SqnZ3uuqxM8Ryq/KL80MeQapFghoE=; b=qOIHRwiNAdSqYwPZ81zEFGICLY0iMSz1jUiFintbLb4sxtgvh9wJODHJnVySvfrYy3 c2kortCAekpJv7Xzxf1O8UEzIFkaE8HZOYVgl8G1KS+EwEr/CloB+GJowtDmyoWO1oP0 K8vboHifXuoWAODEd2JrWlwp46Fi51eXhe8TI= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; b=JC30RbqPJuFeMUvk4t6lI3jf/u72gdmsJEHzGXPkKko5kE4AMFpDnOwUbJ5bn1scTy u1H8/TZd3Y99fZoPPwE0+OR+pDzkWaOeWsmOWG9jKuo+BywCNrNE8XXN36PT3ZuACyhU r9KL/WzVupZi5aA92WC1sXskg19kH7VnJP1NI= MIME-Version: 1.0 Received: by 10.204.64.136 with SMTP id e8mr651287bki.46.1248511044324; Sat, 25 Jul 2009 01:37:24 -0700 (PDT) In-Reply-To: <1248478502.3510.96.camel@fz.local> References: <1248478502.3510.96.camel@fz.local> Date: Sat, 25 Jul 2009 10:37:24 +0200 Message-ID: From: "Vladimir 'phcoder' Serbinenko" To: The development of GRUB 2 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) Subject: Re: [Fwd: Bug#503344: Grub-pc fails on IBM x3250 configured with RAID-1] 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: Sat, 25 Jul 2009 08:37:31 -0000 On Sat, Jul 25, 2009 at 1:35 AM, Felix Zielcke wrote: > Is this an acceptable fix? > Though I have the feeling this isn't a proper one. > >> >> The fix is to assign grub_errno before making the call to >> grub_file_get_device_name(): Just check whether returned device_name is 0 or not >> >> diff --git a/kern/file.c b/kern/file.c >> index adf55da..5e605f9 100644 >> --- a/kern/file.c >> +++ b/kern/file.c >> @@ -59,6 +59,7 @@ grub_file_open (const char *name) >> =A0 =A0 char *device_name; >> =A0 =A0 char *file_name; >> >> + =A0grub_errno =3D GRUB_ERR_NONE; =A0/* Used as error flag */ >> =A0 =A0 device_name =3D grub_file_get_device_name (name); >> =A0 =A0 if (grub_errno) >> =A0 =A0 =A0 return 0; > > > -- > Felix Zielcke > Proud Debian Maintainer > > > > _______________________________________________ > Grub-devel mailing list > Grub-devel@gnu.org > http://lists.gnu.org/mailman/listinfo/grub-devel > --=20 Regards Vladimir 'phcoder' Serbinenko Personal git repository: http://repo.or.cz/w/grub2/phcoder.git