merge mainline into ofwfb

This commit is contained in:
Vladimir 'phcoder' Serbinenko 2010-02-06 15:54:01 +01:00
commit e190e3d2cc
63 changed files with 7613 additions and 183 deletions

View file

@ -441,7 +441,7 @@ grub_disk_read (grub_disk_t disk, grub_disk_addr_t sector,
grub_errno = GRUB_ERR_NONE;
num = ((size + real_offset + pos + GRUB_DISK_SECTOR_SIZE - 1)
num = ((size + real_offset + GRUB_DISK_SECTOR_SIZE - 1)
>> GRUB_DISK_SECTOR_BITS);
p = grub_realloc (tmp_buf, num << GRUB_DISK_SECTOR_BITS);
@ -458,7 +458,7 @@ grub_disk_read (grub_disk_t disk, grub_disk_addr_t sector,
goto finish;
}
grub_memcpy (buf, tmp_buf + pos + real_offset, size);
grub_memcpy (buf, tmp_buf + real_offset, size);
/* Call the read hook, if any. */
if (disk->read_hook)

View file

@ -152,7 +152,7 @@ grub_devalias_iterate (int (*hook) (struct grub_ieee1275_devalias *alias))
/* Find the first property. */
aliasname[0] = '\0';
while (grub_ieee1275_next_property (aliases, aliasname, aliasname))
while (grub_ieee1275_next_property (aliases, aliasname, aliasname) > 0)
{
grub_ieee1275_phandle_t dev;
grub_ssize_t pathlen;
@ -391,7 +391,7 @@ grub_ieee1275_encode_devname (const char *path)
char *partition = grub_ieee1275_parse_args (path, GRUB_PARSE_PARTITION);
char *encoding;
if (partition)
if (partition && partition[0])
{
unsigned int partno = grub_strtoul (partition, 0, 0);

View file

@ -206,7 +206,6 @@ grub_vprintf (const char *fmt, va_list args)
int ret;
ret = grub_vsnprintf_real (0, 0, fmt, args);
grub_refresh ();
return ret;
}
@ -876,9 +875,6 @@ grub_vsnprintf_real (char *str, grub_size_t max_len, const char *fmt, va_list ar
if (str)
*str = '\0';
if (count && !str)
grub_refresh ();
return count;
}

View file

@ -79,6 +79,8 @@ grub_getkey (void)
{
grub_term_input_t term;
grub_refresh ();
while (1)
{
FOR_ACTIVE_TERM_INPUTS(term)