]> source.dussan.org Git - tigervnc.git/commitdiff
Keep alpha in cursor alpha conversion
authorPierre Ossman <ossman@cendio.se>
Mon, 2 Oct 2017 09:06:04 +0000 (11:06 +0200)
committerPierre Ossman <ossman@cendio.se>
Mon, 2 Oct 2017 09:06:04 +0000 (11:06 +0200)
Don't touch the existing value or we might mess it up when we avoid
division by zero.

common/rfb/CMsgReader.cxx

index eee6d277362d4926dc2e5866b47a61258aef354e..c325d48fcc6f1c67fc8fc6edeaaeb07539f99b57 100644 (file)
@@ -340,7 +340,6 @@ void CMsgReader::readSetCursorWithAlpha(int width, int height, const Point& hots
     buf[0] = (unsigned)buf[0] * 255/alpha;
     buf[1] = (unsigned)buf[1] * 255/alpha;
     buf[2] = (unsigned)buf[2] * 255/alpha;
-    buf[3] = alpha;
 
     buf += 4;
   }