vt(4): Refuse to load a font if hw.vga.textmode is selected

Before, the font was loaded and the window size recalculated, giving an
unusable terminal, even if the actual font didn't change.

Reported by:	beeessdee@ruggedinbox.com
MFC of:		r273330
This commit is contained in:
dumbbell 2014-10-23 13:32:01 +00:00
parent 9d96d4ad45
commit 5cd9154e6b

View File

@ -2200,6 +2200,9 @@ vtterm_ioctl(struct terminal *tm, u_long cmd, caddr_t data,
case PIO_VFONT: {
struct vt_font *vf;
if (vd->vd_flags & VDF_TEXTMODE)
return (ENOTSUP);
error = vtfont_load((void *)data, &vf);
if (error != 0)
return (error);