vnc.c (01b601f06154c0d35f945b1321ddb3f39530cc43) vnc.c (97efe4f961dcf5a0126baa75e8a6bff66d33186f)
1/*
2 * QEMU VNC display driver
3 *
4 * Copyright (C) 2006 Anthony Liguori <anthony@codemonkey.ws>
5 * Copyright (C) 2006 Fabrice Bellard
6 * Copyright (C) 2009 Red Hat, Inc
7 *
8 * Permission is hereby granted, free of charge, to any person obtaining a copy

--- 2445 unchanged lines hidden (view full) ---

2454
2455 vs->client_width = pixman_image_get_width(vs->vd->server);
2456 vs->client_height = pixman_image_get_height(vs->vd->server);
2457 vnc_write_u16(vs, vs->client_width);
2458 vnc_write_u16(vs, vs->client_height);
2459
2460 pixel_format_message(vs);
2461
1/*
2 * QEMU VNC display driver
3 *
4 * Copyright (C) 2006 Anthony Liguori <anthony@codemonkey.ws>
5 * Copyright (C) 2006 Fabrice Bellard
6 * Copyright (C) 2009 Red Hat, Inc
7 *
8 * Permission is hereby granted, free of charge, to any person obtaining a copy

--- 2445 unchanged lines hidden (view full) ---

2454
2455 vs->client_width = pixman_image_get_width(vs->vd->server);
2456 vs->client_height = pixman_image_get_height(vs->vd->server);
2457 vnc_write_u16(vs, vs->client_width);
2458 vnc_write_u16(vs, vs->client_height);
2459
2460 pixel_format_message(vs);
2461
2462 if (qemu_name)
2462 if (qemu_name) {
2463 size = snprintf(buf, sizeof(buf), "QEMU (%s)", qemu_name);
2463 size = snprintf(buf, sizeof(buf), "QEMU (%s)", qemu_name);
2464 else
2464 if (size > sizeof(buf)) {
2465 size = sizeof(buf);
2466 }
2467 } else {
2465 size = snprintf(buf, sizeof(buf), "QEMU");
2468 size = snprintf(buf, sizeof(buf), "QEMU");
2469 }
2466
2467 vnc_write_u32(vs, size);
2468 vnc_write(vs, buf, size);
2469 vnc_flush(vs);
2470
2471 vnc_client_cache_auth(vs);
2472 vnc_qmp_event(vs, QAPI_EVENT_VNC_INITIALIZED);
2473

--- 1437 unchanged lines hidden ---
2470
2471 vnc_write_u32(vs, size);
2472 vnc_write(vs, buf, size);
2473 vnc_flush(vs);
2474
2475 vnc_client_cache_auth(vs);
2476 vnc_qmp_event(vs, QAPI_EVENT_VNC_INITIALIZED);
2477

--- 1437 unchanged lines hidden ---