qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH v2 01/15] vnc: don't set the quality if lossy encodi


From: Corentin Chary
Subject: [Qemu-devel] [PATCH v2 01/15] vnc: don't set the quality if lossy encoding are disabled
Date: Thu, 11 Nov 2010 17:56:50 +0100

This should not change the current behavior, but if any new
encoding try to use the tight quality, it will always be set
to -1 when lossy encodings are disabled.

Signed-off-by: Corentin Chary <address@hidden>
---
 ui/vnc.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/ui/vnc.c b/ui/vnc.c
index 864342e..7391311 100644
--- a/ui/vnc.c
+++ b/ui/vnc.c
@@ -1780,7 +1780,9 @@ static void set_encodings(VncState *vs, int32_t 
*encodings, size_t n_encodings)
             vs->tight.compression = (enc & 0x0F);
             break;
         case VNC_ENCODING_QUALITYLEVEL0 ... VNC_ENCODING_QUALITYLEVEL0 + 9:
-            vs->tight.quality = (enc & 0x0F);
+            if (vs->vd->lossy) {
+                vs->tight.quality = (enc & 0x0F);
+            }
             break;
         default:
             VNC_DEBUG("Unknown encoding: %d (0x%.8x): %d\n", i, enc, enc);
-- 
1.7.3.2




reply via email to

[Prev in Thread] Current Thread [Next in Thread]