+2013-10-03 Vladimir Serbinenko <phcoder@gmail.com>
+
+ * grub-core/term/gfxterm.c: Add flag "functional" to skip input when
+ changing windows to avoid crash.
+
2013-10-03 Vladimir Serbinenko <phcoder@gmail.com>
* grub-core/kern/arm/cache.c: Add v5 write-through cache support.
struct grub_colored_char *text_buffer;
int total_scroll;
+
+ int functional;
};
struct grub_gfxterm_window
static void
grub_virtual_screen_free (void)
{
+ virtual_screen.functional = 0;
+
/* If virtual screen has been allocated, free it. */
if (virtual_screen.text_buffer != 0)
{
virtual_screen.text_buffer[i].code.ncomb = 0;
clear_char (&(virtual_screen.text_buffer[i]));
}
+ if (grub_errno)
+ return grub_errno;
- return grub_errno;
+ virtual_screen.functional = 1;
+
+ return GRUB_ERR_NONE;
}
void
grub_gfxterm_putchar (struct grub_term_output *term,
const struct grub_unicode_glyph *c)
{
+ if (!virtual_screen.functional)
+ return;
+
if (c->base == '\a')
/* FIXME */
return;