Blame SOURCES/tigervnc-fix-typo-in-mirror-monitor-detection.patch

d7e56c
From 2daf4126882f82b6e392dfbae87205dbdc559c3d Mon Sep 17 00:00:00 2001
d7e56c
From: Pierre Ossman <ossman@cendio.se>
d7e56c
Date: Thu, 23 Dec 2021 15:58:00 +0100
d7e56c
Subject: [PATCH] Fix typo in mirror monitor detection
d7e56c
d7e56c
Bug introduced in fb561eb but still somehow passed manual testing.
d7e56c
Resulted in some stray reads off the end of the stack, which were
d7e56c
hopefully harmless.
d7e56c
---
d7e56c
 vncviewer/MonitorIndicesParameter.cxx | 8 ++++----
d7e56c
 1 file changed, 4 insertions(+), 4 deletions(-)
d7e56c
d7e56c
diff --git a/vncviewer/MonitorIndicesParameter.cxx b/vncviewer/MonitorIndicesParameter.cxx
d7e56c
index 5130831cb..4ac74dd1a 100644
d7e56c
--- a/vncviewer/MonitorIndicesParameter.cxx
d7e56c
+++ b/vncviewer/MonitorIndicesParameter.cxx
d7e56c
@@ -211,13 +211,13 @@ std::vector<MonitorIndicesParameter::Monitor> MonitorIndicesParameter::fetchMoni
d7e56c
         // Only keep a single entry for mirrored screens
d7e56c
         match = false;
d7e56c
         for (int j = 0; j < ((int) monitors.size()); j++) {
d7e56c
-            if (monitors[i].x != monitor.x)
d7e56c
+            if (monitors[j].x != monitor.x)
d7e56c
                 continue;
d7e56c
-            if (monitors[i].y != monitor.y)
d7e56c
+            if (monitors[j].y != monitor.y)
d7e56c
                 continue;
d7e56c
-            if (monitors[i].w != monitor.w)
d7e56c
+            if (monitors[j].w != monitor.w)
d7e56c
                 continue;
d7e56c
-            if (monitors[i].h != monitor.h)
d7e56c
+            if (monitors[j].h != monitor.h)
d7e56c
                 continue;
d7e56c
d7e56c
             match = true;