* [Qemu-devel] [PATCH] vnc: hextile: do not generate ForegroundSpecified and SubrectsColoured tiles
@ 2009-12-14 20:21 Anthony Liguori
0 siblings, 0 replies; only message in thread
From: Anthony Liguori @ 2009-12-14 20:21 UTC (permalink / raw)
To: qemu-devel; +Cc: Anthony Liguori, Yaniv Kaul
This violates the RFB specification (section 6.6.4). It happens to work with
most clients but it's still wrong.
Reported-by: Yaniv Kaul <ykaul@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
---
vnchextile.h | 4 +---
1 files changed, 1 insertions(+), 3 deletions(-)
diff --git a/vnchextile.h b/vnchextile.h
index c96ede3..432ed89 100644
--- a/vnchextile.h
+++ b/vnchextile.h
@@ -73,7 +73,7 @@ static void CONCAT(send_hextile_tile_, NAME)(VncState *vs,
*last_bg = bg;
}
- if (!*has_fg || *last_fg != fg) {
+ if (n_colors < 3 && (!*has_fg || *last_fg != fg)) {
flags |= 0x04;
*has_fg = 1;
*last_fg = fg;
@@ -165,8 +165,6 @@ static void CONCAT(send_hextile_tile_, NAME)(VncState *vs,
irow += ds_get_linesize(vs->ds) / sizeof(pixel_t);
}
- /* A SubrectsColoured subtile invalidates the foreground color */
- *has_fg = 0;
if (n_data > (w * h * sizeof(pixel_t))) {
n_colors = 4;
flags = 0x01;
--
1.6.2.5
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2009-12-14 20:22 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-12-14 20:21 [Qemu-devel] [PATCH] vnc: hextile: do not generate ForegroundSpecified and SubrectsColoured tiles Anthony Liguori
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).