]> source.dussan.org Git - tigervnc.git/commitdiff
Don't use un-initialized stride to base constructor
authorPierre Ossman <ossman@cendio.se>
Mon, 25 Mar 2019 15:14:49 +0000 (16:14 +0100)
committerPierre Ossman <ossman@cendio.se>
Mon, 25 Mar 2019 15:14:49 +0000 (16:14 +0100)
We can use a dummy value here as we set up the buffer and stride
further down in the constructor.

vncviewer/PlatformPixelBuffer.cxx

index 1e9803eb2c5f7e4d605131af19040ab0ef237d62..ff1935e74765d73d69fc398a56ac6301fed64e36 100644 (file)
@@ -36,7 +36,7 @@ static rfb::LogWriter vlog("PlatformPixelBuffer");
 PlatformPixelBuffer::PlatformPixelBuffer(int width, int height) :
   FullFramePixelBuffer(rfb::PixelFormat(32, 24, false, true,
                                         255, 255, 255, 16, 8, 0),
-                       width, height, 0, stride),
+                       width, height, NULL, 0),
   Surface(width, height)
 #if !defined(WIN32) && !defined(__APPLE__)
   , shminfo(NULL), xim(NULL)