sanity check for qxl, minor spice display channel tweak.
-----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (GNU/Linux) iQIcBAABAgAGBQJUBYWTAAoJEEy22O7T6HE4Fo8P+wW0uE5YiZn9c9PWKbue3Lqz di7K5Wj2Qbf7QdBWql2FBhQi18S3IMqRRgpKXfTI+2MnEC76/ro4EEa7fB6NYZrA WCE1DkfRaeqWAVMTKvlHZsimqznhkl9XtOmVIE71Cfxq9UokpZVwfaravLq+cGmN noccF7ppzl+PKeJJeGPHPND1msapY0sUQ88AE875gjScmfmTjE33eqBO5haOS9Xn d60GvyiCoL2/aC+n5LN1fJt8anZ7dS++HEIJGQeyxxBsbVd3OTLjtael+ghvYGSE sZR9kDW9j/b0oXUjEaYMiMnn2bqURJ3J5B/3TK9Z/bxctMq+umSkHPhyjuxrD30k 1lgot0lzGkpOQiFlxesHhQLUADYGeL5h2kp4Wr0yHCHlfWjSjkugoy8paw9JXgiN bpd83xIT8Rp0wSHmcL2cd06ReKdZ9Tiqv9SPWOG77lSXatD5whSMqN54RKZ1L2L2 lIVx6pAJijq+vTQD7CGUHhsOEAPQoR3lBM5E7HoUsEP7LdKMPmU7W68AwWi/Fv/+ fKwSO/DpOdQc4ACVPDd0Zs12/3FdsH1Xpd25kUq/sSMZ5fvPVD7ZbbjsqxGyIlO8 N3dOP+3EqzmI95oNWleVlGy/BTBMbbUu2hzxCyfRr+dtKJwlGnzc0NpycAGRYDup fPyFdJ660P1KDK391ELa =fVkQ -----END PGP SIGNATURE----- Merge remote-tracking branch 'remotes/spice/tags/pull-spice-20140902-1' into staging sanity check for qxl, minor spice display channel tweak. # gpg: Signature made Tue 02 Sep 2014 09:53:39 BST using RSA key ID D3E87138 # gpg: Good signature from "Gerd Hoffmann (work) <kraxel@redhat.com>" # gpg: aka "Gerd Hoffmann <gerd@kraxel.org>" # gpg: aka "Gerd Hoffmann (private) <kraxel@gmail.com>" * remotes/spice/tags/pull-spice-20140902-1: spice: use console index as display id qxl-render: add more sanity checks Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
commit
30eaca3acd
@ -138,7 +138,9 @@ static void qxl_render_update_area_unlocked(PCIQXLDevice *qxl)
|
|||||||
if (qemu_spice_rect_is_empty(qxl->dirty+i)) {
|
if (qemu_spice_rect_is_empty(qxl->dirty+i)) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if (qxl->dirty[i].left > qxl->dirty[i].right ||
|
if (qxl->dirty[i].left < 0 ||
|
||||||
|
qxl->dirty[i].top < 0 ||
|
||||||
|
qxl->dirty[i].left > qxl->dirty[i].right ||
|
||||||
qxl->dirty[i].top > qxl->dirty[i].bottom ||
|
qxl->dirty[i].top > qxl->dirty[i].bottom ||
|
||||||
qxl->dirty[i].right > qxl->guest_primary.surface.width ||
|
qxl->dirty[i].right > qxl->guest_primary.surface.width ||
|
||||||
qxl->dirty[i].bottom > qxl->guest_primary.surface.height) {
|
qxl->dirty[i].bottom > qxl->guest_primary.surface.height) {
|
||||||
|
@ -853,7 +853,6 @@ int qemu_spice_add_interface(SpiceBaseInstance *sin)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static GSList *spice_consoles;
|
static GSList *spice_consoles;
|
||||||
static int display_id;
|
|
||||||
|
|
||||||
bool qemu_spice_have_display_interface(QemuConsole *con)
|
bool qemu_spice_have_display_interface(QemuConsole *con)
|
||||||
{
|
{
|
||||||
@ -868,7 +867,7 @@ int qemu_spice_add_display_interface(QXLInstance *qxlin, QemuConsole *con)
|
|||||||
if (g_slist_find(spice_consoles, con)) {
|
if (g_slist_find(spice_consoles, con)) {
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
qxlin->id = display_id++;
|
qxlin->id = qemu_console_get_index(con);
|
||||||
spice_consoles = g_slist_append(spice_consoles, con);
|
spice_consoles = g_slist_append(spice_consoles, con);
|
||||||
return qemu_spice_add_interface(&qxlin->base);
|
return qemu_spice_add_interface(&qxlin->base);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user