aboutsummaryrefslogtreecommitdiff
path: root/ui/vnc-enc-zrle.c
diff options
context:
space:
mode:
Diffstat (limited to 'ui/vnc-enc-zrle.c')
-rw-r--r--ui/vnc-enc-zrle.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/ui/vnc-enc-zrle.c b/ui/vnc-enc-zrle.c
index 016a406..917d384 100644
--- a/ui/vnc-enc-zrle.c
+++ b/ui/vnc-enc-zrle.c
@@ -260,7 +260,8 @@ static int zrle_send_framebuffer_update(VncState *vs, int x, int y,
int zywrle_level;
if (vs->zrle.type == VNC_ENCODING_ZYWRLE) {
- if (!vs->vd->lossy || vs->tight.quality < 0 || vs->tight.quality == 9) {
+ if (!vs->vd->lossy || vs->tight.quality == (uint8_t)-1
+ || vs->tight.quality == 9) {
zywrle_level = 0;
vs->zrle.type = VNC_ENCODING_ZRLE;
} else if (vs->tight.quality < 3) {