On Fri Mar 24 17:09:03 2023 +0000, Alexandros Frantzis wrote:
@julliard
I should note that using shared memory that way is not allowed in
Wine. It's not considered acceptable that one crashing app can take down the entire session. Shared state has to be stored in the Wine server. I was under the impression that the `NtCreateSection("\??\WaylandDisplayDevices", file=0)` call I am using is doing effectively that, i.e., it creates a server-owned shared memory region, that stays alive as long as there are handles to it. It's unclear to me how an app crashing would take the session down in this case. Could you elaborate? Is there some other server provided mechanism that would be preferable to use?
@rbernon
The shared memory approach in this MR is effectively trying to establish a shared truth for the host settings (so a kind of driver built-in xrandr). So, I guess the suggestion is to use CURRENT_SETTINGS as that shared truth instead, correct?
I will need to think about (and experiment with) this a bit more, but at the very least I think I would need to be able to attach (and be able to retrieve from any process) some driver-specific display device properties (the Wayland output name it corresponds to, the compositor scale and native mode etc).
Thanks!