Bug 4516 - resizing to two identical monitors is unstable
Summary: resizing to two identical monitors is unstable
Status: CLOSED FIXED
Alias: None
Product: ThinLinc
Classification: Unclassified
Component: VNC (show other bugs)
Version: trunk
Hardware: PC Unknown
: P2 Normal
Target Milestone: 4.10.0
Assignee: Pierre Ossman
URL:
Keywords: ossman_tester, relnotes, upstream
: 5359 (view as bug list)
Depends on: 7158
Blocks:
  Show dependency treegraph
 
Reported: 2013-01-17 09:32 CET by Pierre Ossman
Modified: 2018-09-26 12:18 CEST (History)
4 users (show)

See Also:
Acceptance Criteria:


Attachments

Description Pierre Ossman cendio 2013-01-17 09:32:50 CET
We got a report on Issue 13851 that reconnecting to a single monitor 1920x1200 session with a dual monitor 1920x1200 machine resulted in a 1920x1200 session centred across the edge between the two local monitors.
Comment 1 Pierre Ossman cendio 2013-01-17 09:36:40 CET
Did some local testing. Could not reproduce the exact reported problem, but got another one instead:

 Connections: closed: 127.0.0.1::53712 (Desktop configured a different screen
              layout than requested)

The issue seems to vary depending on local WM. These are the results:


System           From              To                    Result
---------------------------------------------------------------
F17/Gnome 3      1920x1200         2 * 1920x1200         Fail
F17/Gnome 3      1920x1200         1920x1200/1440x900    OK
F17/Gnome 3      1600x1200         2 * 1600x1200         Fail
F17/Gnome 3      1920x1200         1920x1200/1440x1050   OK
C6/Xfce          1600x1200         2 * 1600x1200         OK
Comment 2 Pierre Ossman cendio 2013-01-17 09:41:38 CET
Also noteworthy is that this only happens the first time the session is resized to two monitors. After having been successfully resized to the 1920x1200/1440x900 combination, I could successfully switch back and forth between 1920x1200 and 2 * 1920x1200 (which previously did not work).
Comment 6 Pierre Ossman cendio 2014-10-17 16:37:25 CEST
Managed to get what seems to be this bug with a 1280x1024 + 1600x1200 combo as well.
Comment 7 Peter Åstrand cendio 2014-11-18 13:46:35 CET
*** Bug 5359 has been marked as a duplicate of this bug. ***
Comment 9 Peter Åstrand cendio 2018-05-07 08:49:28 CEST
I believe this bug is caused by this problem mentioned in ScreenSet.h:

// FIXME: List order shouldn't matter
inline bool operator==(const ScreenSet& r) const { return screens == r.screens; }
inline bool operator!=(const ScreenSet& r) const { return screens != r.screens; }

In my testing, I got "Desktop configured a different screen layout than requested" and with debug printing:

server->screenLayout:
 VNCSConnST:  2 screen(s)
    2007237709 (0x77a4044d): 1280x1024+0+0 (flags
              0x00000000)
     704877633 (0x2a039441): 1920x1080+1280+0 (flags
              0x00000000)

layout:
 VNCSConnST:  2 screen(s)
     704877633 (0x2a039441): 1920x1080+1280+0 (flags
              0x00000000)
    2007237709 (0x77a4044d): 1280x1024+0+0 (flags
              0x00000000)

Thus, actually same but in different order.
Comment 10 Peter Åstrand cendio 2018-05-07 10:06:02 CEST
I have fixed this upstream now:

https://github.com/TigerVNC/tigervnc/commit/a9d7069f9c6185796a44c9790f6badd0b59124f9
Comment 12 Pierre Ossman cendio 2018-09-26 12:18:24 CEST
Works well. I tested the following with a Fedora 28 client and Ubuntu 18.04 server:

1. Start a new 1024x768 windowed session
2. Go fullscreen over a single 1920x1200 monitor
3. Open options and change to fullscreen over all monitors, effectively adding the second 1920x1200 monitor

This gets me disconnected with 4.9.0 but works fine with master.

Note You need to log in before you can comment on or make changes to this bug.