From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1MVuLX-0003YX-HT for mharc-grub-devel@gnu.org; Tue, 28 Jul 2009 17:36:31 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MVuLV-0003XS-Kc for grub-devel@gnu.org; Tue, 28 Jul 2009 17:36:29 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MVuLP-0003SN-Mu for grub-devel@gnu.org; Tue, 28 Jul 2009 17:36:29 -0400 Received: from [199.232.76.173] (port=35891 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MVuLP-0003S9-Ga for grub-devel@gnu.org; Tue, 28 Jul 2009 17:36:23 -0400 Received: from moutng.kundenserver.de ([212.227.126.171]:59675) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MVuLO-0003VG-Uj for grub-devel@gnu.org; Tue, 28 Jul 2009 17:36:23 -0400 Received: from [85.180.13.133] (e180013133.adsl.alicedsl.de [85.180.13.133]) by mrelayeu.kundenserver.de (node=mrelayeu3) with ESMTP (Nemesis) id 0MKxQS-1MVuLN3bh3-000p5F; Tue, 28 Jul 2009 23:36:22 +0200 From: Felix Zielcke To: The development of GRUB 2 In-Reply-To: <20090728174223.GC32726@thorin> References: <1340f8530907191211o53119415nf7510cc1e7a89ee1@mail.gmail.com> <1340f8530907271358g2634fe16w15d4297b1b8f30df@mail.gmail.com> <20090728174223.GC32726@thorin> Content-Type: text/plain Date: Tue, 28 Jul 2009 23:37:13 +0200 Message-Id: <1248817033.3682.3.camel@fz.local> Mime-Version: 1.0 X-Mailer: Evolution 2.27.4 Content-Transfer-Encoding: 7bit X-Provags-ID: V01U2FsdGVkX1/ukQ714mp89pX+8jXa8mJ7XMQDliCPJlZCMk+ p7TFZPvk0qdm6g49claW7GWPo17vVDSA0n9WSGyHkyM8UdWFlK PTB16hCZN9LY7kEDwuLXoYBZIhRqz8m X-detected-operating-system: by monty-python.gnu.org: Genre and OS details not recognized. Subject: Re: [PATCH] Bug fix for LVM 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, 28 Jul 2009 21:36:30 -0000 Am Dienstag, den 28.07.2009, 19:42 +0200 schrieb Robert Millan: > On Tue, Jul 28, 2009 at 11:15:09PM +0800, Bean wrote: > > > +static int > > +probe_raid_level (grub_disk_t disk) > > +{ > > + if (disk->dev->id != GRUB_DISK_DEVICE_RAID_ID) > > + return -1; > > + > > + return ((struct grub_raid_array *) disk->data)->level; > > +} > > Since this an ad-hoc function, could you put it in the same block that > needs it? If 'static' qualifier is present, it won't result in nested > function AFAICT. > GCC manual [0] says: A nested function always has no linkage. Declaring one with extern or static is erroneous. [0] http://gcc.gnu.org/onlinedocs/gcc-4.4.1/gcc/Nested-Functions.html#Nested-Functions -- Felix Zielcke Proud Debian Maintainer