提交 1802651c 编写于 作者: J Jan Kiszka 提交者: Stefan Hajnoczi

Align dummy display to fixed-size active console

This fixes e.g. '-vga none -monitor vc:120Cx50C'.
Signed-off-by: NJan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: NStefan Hajnoczi <stefanha@linux.vnet.ibm.com>
上级 f9245e10
......@@ -1349,8 +1349,15 @@ static struct DisplayAllocator default_allocator = {
static void dumb_display_init(void)
{
DisplayState *ds = qemu_mallocz(sizeof(DisplayState));
int width = 640;
int height = 480;
ds->allocator = &default_allocator;
ds->surface = qemu_create_displaysurface(ds, 640, 480);
if (is_fixedsize_console()) {
width = active_console->g_width;
height = active_console->g_height;
}
ds->surface = qemu_create_displaysurface(ds, width, height);
register_displaystate(ds);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册