fix a completion buf, add floppy devices into the device map file unconditionally.
This commit is contained in:
parent
d7c7eb7897
commit
0612bf14c0
4 changed files with 17 additions and 10 deletions
|
@ -1,3 +1,10 @@
|
||||||
|
1999-10-31 OKUJI Yoshinori <okuji@kuicr.kyoto-u.ac.jp>
|
||||||
|
|
||||||
|
* grub/asmstub.c (init_device_map): Add a floppy device name
|
||||||
|
into the device map file even if check_device fails.
|
||||||
|
* stage2/char_io.c [!STAGE1_5] (get_cmdline): Clear ERRNUM after
|
||||||
|
calling print_completions.
|
||||||
|
|
||||||
1999-10-29 OKUJI Yoshinori <okuji@kuicr.kyoto-u.ac.jp>
|
1999-10-29 OKUJI Yoshinori <okuji@kuicr.kyoto-u.ac.jp>
|
||||||
|
|
||||||
* stage2/asm.S (track_int13): Defined unconditionally. Do not
|
* stage2/asm.S (track_int13): Defined unconditionally. Do not
|
||||||
|
|
|
@ -341,14 +341,13 @@ init_device_map (void)
|
||||||
break;
|
break;
|
||||||
|
|
||||||
get_floppy_disk_name (name, i);
|
get_floppy_disk_name (name, i);
|
||||||
if (check_device (name))
|
/* In floppies, write the map, whether check_device succeeds
|
||||||
{
|
or not, because the user just does not insert floppies. */
|
||||||
assign_device_name (i, name);
|
if (fp)
|
||||||
|
fprintf (fp, "(fd%d)\t%s\n", i, name);
|
||||||
|
|
||||||
/* If the device map file is opened, write the map. */
|
if (check_device (name))
|
||||||
if (fp)
|
assign_device_name (i, name);
|
||||||
fprintf (fp, "(fd%d)\t%s\n", i, name);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* IDE disks. */
|
/* IDE disks. */
|
||||||
|
|
|
@ -408,6 +408,7 @@ get_cmdline (char *prompt, char *cmdline, int maxlen,
|
||||||
grub_memmove (completion_buffer, buf + i, lpos - i);
|
grub_memmove (completion_buffer, buf + i, lpos - i);
|
||||||
completion_buffer[lpos - i] = 0;
|
completion_buffer[lpos - i] = 0;
|
||||||
ret = print_completions (is_filename, 1);
|
ret = print_completions (is_filename, 1);
|
||||||
|
errnum = ERR_NONE;
|
||||||
|
|
||||||
if (ret >= 0)
|
if (ret >= 0)
|
||||||
{
|
{
|
||||||
|
|
|
@ -1055,7 +1055,7 @@ print_completions (int is_filename, int is_completion)
|
||||||
{
|
{
|
||||||
errnum = 0;
|
errnum = 0;
|
||||||
|
|
||||||
if (*buf != '/' && (incomplete || ! *ptr))
|
if (*buf == '(' && (incomplete || ! *ptr))
|
||||||
{
|
{
|
||||||
if (! part_choice)
|
if (! part_choice)
|
||||||
{
|
{
|
||||||
|
@ -1142,7 +1142,7 @@ print_completions (int is_filename, int is_completion)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (*ptr == '/')
|
else if (ptr && *ptr == '/')
|
||||||
{
|
{
|
||||||
/* filename completions */
|
/* filename completions */
|
||||||
if (! is_completion)
|
if (! is_completion)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue