bug-grub
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH] use dynamical allocation in device.c:get_*_name ()


From: Robert Millan
Subject: [PATCH] use dynamical allocation in device.c:get_*_name ()
Date: Fri, 18 Jul 2003 16:49:41 +0000
User-agent: Mutt/1.5.4i

Hello!

This patch fixes lib/device.c to use dynamic allocation for the
device names obtained in get_*_name () functions:

 - the name variable is returned by the functions instead of
   passing by reference, so that they can allocate it themselves.
 - the get_*_name functions use asprintf() to allocate the device
   name dynamicaly.
 - for NetBSD, it still uses static allocation since the "opendisk"
   call is unable (that i know of) to deal with dynamic buffers.

This fix is needed to work for kernels that have device names longer than
16 chars, and for GCS compliance (section 4.1).

-- 
Robert Millan

Attachment: grub.diff
Description: Text document


reply via email to

[Prev in Thread] Current Thread [Next in Thread]