All of lore.kernel.org
 help / color / mirror / Atom feed
From: Brian Kress <kressb@moose.net>
To: qemu-devel@nongnu.org
Subject: [Qemu-devel] [PATCH] Fix incorrect attempt to clear a flag in vnc.c
Date: Sat, 14 Feb 2009 07:48:10 -0500	[thread overview]
Message-ID: <4996BD8A.2050807@moose.net> (raw)

[-- Attachment #1: Type: text/plain, Size: 263 bytes --]

In vnc.c in pixel_format_message, the code tries to clear the 
QEMU_ALLOCATED_FLAG
from the client display surface, however it uses the wrong operator and 
ends up enabling all
other flags.  Most notably this enables the big endian flag and causes 
some chaos. 


[-- Attachment #2: patch.flagfix --]
[-- Type: text/plain, Size: 502 bytes --]

Index: vnc.c
===================================================================
--- vnc.c	(revision 6619)
+++ vnc.c	(working copy)
@@ -1421,7 +1421,7 @@
     else if (vs->ds->surface->pf.bits_per_pixel == 8)
         vs->send_hextile_tile = send_hextile_tile_8;
     vs->clientds = *(vs->ds->surface);
-    vs->clientds.flags |= ~QEMU_ALLOCATED_FLAG;
+    vs->clientds.flags &= ~QEMU_ALLOCATED_FLAG;
     vs->write_pixels = vnc_write_pixels_copy;
 
     vnc_write(vs, pad, 3);           /* padding */

             reply	other threads:[~2009-02-14 12:48 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-02-14 12:48 Brian Kress [this message]
2009-02-14 21:06 ` [Qemu-devel] [PATCH] Fix incorrect attempt to clear a flag in vnc.c Anthony Liguori
2009-02-14 21:20   ` Brian Kress
2009-04-07 19:59     ` Aurelien Jarno

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4996BD8A.2050807@moose.net \
    --to=kressb@moose.net \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.