2005-07-18 Yoshinori K. Okuji <okuji@enbug.org>
* commands/ls.c (grub_ls_list_disks): Print the filesystem information on each device, if it does not have partitions. Print "Device" instead of "Disk", because this function is not specific to disk devices. * normal/main.c (grub_rescue_cmd_normal): Make the variable CONFIG static to ensure that it is put on the memory rather than a register.
This commit is contained in:
parent
502c87e80e
commit
5f3607e09d
3 changed files with 41 additions and 4 deletions
11
ChangeLog
11
ChangeLog
|
@ -1,3 +1,14 @@
|
|||
2005-07-18 Yoshinori K. Okuji <okuji@enbug.org>
|
||||
|
||||
* commands/ls.c (grub_ls_list_disks): Print the filesystem
|
||||
information on each device, if it does not have partitions. Print
|
||||
"Device" instead of "Disk", because this function is not specific
|
||||
to disk devices.
|
||||
|
||||
* normal/main.c (grub_rescue_cmd_normal): Make the variable CONFIG
|
||||
static to ensure that it is put on the memory rather than a
|
||||
register.
|
||||
|
||||
2005-07-17 Yoshinori Okuji <okuji@enbug.org>
|
||||
|
||||
* commands/cat.c (GRUB_MOD_INIT): Use better documentation.
|
||||
|
|
|
@ -71,7 +71,33 @@ grub_ls_list_disks (int longlist)
|
|||
if (dev)
|
||||
{
|
||||
if (longlist)
|
||||
grub_printf ("Disk: %s\n", name);
|
||||
{
|
||||
grub_printf ("Device: %s", name);
|
||||
|
||||
if (! dev->disk || ! dev->disk->has_partitions)
|
||||
{
|
||||
grub_fs_t fs;
|
||||
char *label;
|
||||
|
||||
fs = grub_fs_probe (dev);
|
||||
grub_errno = GRUB_ERR_NONE;
|
||||
|
||||
grub_printf (", Filesystem type %s",
|
||||
fs ? fs->name : "Unknown");
|
||||
|
||||
(fs->label) (dev, &label);
|
||||
if (grub_errno == GRUB_ERR_NONE)
|
||||
{
|
||||
if (label && grub_strlen (label))
|
||||
grub_printf (", Label: %s", label);
|
||||
grub_free (label);
|
||||
}
|
||||
else
|
||||
grub_errno = GRUB_ERR_NONE;
|
||||
}
|
||||
|
||||
grub_putchar ('\n');
|
||||
}
|
||||
else
|
||||
grub_printf ("(%s) ", name);
|
||||
|
||||
|
@ -91,7 +117,6 @@ grub_ls_list_disks (int longlist)
|
|||
grub_putchar ('\n');
|
||||
grub_refresh ();
|
||||
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
|
@ -490,8 +490,9 @@ grub_rescue_cmd_normal (int argc, char *argv[])
|
|||
{
|
||||
if (argc == 0)
|
||||
{
|
||||
/* Guess the config filename. */
|
||||
char *config;
|
||||
/* Guess the config filename. It is necessary to make CONFIG static,
|
||||
so that it won't get broken by longjmp. */
|
||||
static char *config;
|
||||
const char *prefix;
|
||||
|
||||
prefix = grub_env_get ("prefix");
|
||||
|
|
Loading…
Reference in a new issue