+2015-01-20 Vladimir Serbinenko <phcoder@gmail.com>
+
+ * include/grub/term.h: Avoid returining 0-sized terminal
+ as it may lead to division by zero.
+
2015-01-20 Vladimir Serbinenko <phcoder@gmail.com>
* grub-core/fs/zfs.c: Avoid divisions by zero.
static inline unsigned grub_term_width (struct grub_term_output *term)
{
- return term->getwh(term).x;
+ return term->getwh(term).x ? : 80;
}
static inline unsigned grub_term_height (struct grub_term_output *term)
{
- return term->getwh(term).y;
+ return term->getwh(term).y ? : 24;
}
static inline struct grub_term_coordinate