summaryrefslogtreecommitdiff
path: root/user/tigervnc/initialise-var.patch
blob: f58a4dadc6f539697b5cf805dde05113c34e192f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
From 44cf1d64ecf80c061c0a2b0f0167094e58782102 Mon Sep 17 00:00:00 2001
From: Pierre Ossman <ossman@cendio.se>
Date: Mon, 25 Mar 2019 16:14:49 +0100
Subject: [PATCH] Don't use un-initialized stride to base constructor

We can use a dummy value here as we set up the buffer and stride
further down in the constructor.
---
 vncviewer/PlatformPixelBuffer.cxx | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/vncviewer/PlatformPixelBuffer.cxx b/vncviewer/PlatformPixelBuffer.cxx
index 1e9803eb2..ff1935e74 100644
--- a/vncviewer/PlatformPixelBuffer.cxx
+++ b/vncviewer/PlatformPixelBuffer.cxx
@@ -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)