FS#77853 - [openbox] glib2 2.76.0 breaks many Steam games fullscreen vs Alt-Tab behavior

Attached to Project: Community Packages
Opened by Uli S (uqs) - Tuesday, 14 March 2023, 20:32 GMT
Last edited by Chih-Hsuan Yen (yan12125) - Tuesday, 21 March 2023, 17:09 GMT
Task Type Bug Report
Category Packages
Status Closed
Assigned To Chih-Hsuan Yen (yan12125)
Architecture All
Severity Medium
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 2
Private No

Details

Description: I bisected this down to the following package. Upgrading glib2 (2.74.6-1 -> 2.76.0-1) breaks the screen rendering when alt-tabbing out of Steam games like Super Meat Boy or Stardew Valley or Divinity Original Sin. The screen flickers and is garbled, not showing the desktop or whatever one alt-tabbed to.

Downgrading glib2 back to 2.74.6-1 (and accountsservice as a dependency), rebooting, and trying Steam games and it's back to a working alt-tab behavior.

I'm running Openbox and I don't think I'm running a compositor nor Wayland.

Additional info:
* package version(s)
glib2 (2.74.6-1 -> 2.76.0-1)
* config and/or log files etc.
* link to upstream bug report, if any
didn't even find the glib changelog, tbh

Steps to reproduce:
This task depends upon

Closed by  Chih-Hsuan Yen (yan12125)
Tuesday, 21 March 2023, 17:09 GMT
Reason for closing:  Fixed
Additional comments about closing:  openbox 3.6.1-10
Comment by Toolybird (Toolybird) - Tuesday, 14 March 2023, 20:36 GMT Comment by Chih-Hsuan Yen (yan12125) - Wednesday, 15 March 2023, 06:16 GMT
Also related: https://bbs.archlinux.org/viewtopic.php?id=284299

---

Per valgrind, this looks like a use-after-free bug.

==260432== Invalid read of size 8
==260432== at 0x125224: UnknownInlinedFun (client.c:2698)
==260432== by 0x125224: client_calc_layer (client.c:2729)
==260432== by 0x138170: event_process.lto_priv.0 (event.c:582)
==260432== by 0x48B3468: event_read (xqueue.c:338)
==260432== by 0x4AACAFA: UnknownInlinedFun (gmain.c:3460)
==260432== by 0x4AACAFA: g_main_context_dispatch (gmain.c:4200)
==260432== by 0x4B095D8: g_main_context_iterate.constprop.0 (gmain.c:4276)
==260432== by 0x4AAC0CE: g_main_loop_run (gmain.c:4479)
==260432== by 0x1194EF: main (openbox.c:382)
==260432== Address 0x10e98a38 is 8 bytes inside a block of size 24 free'd
==260432== at 0x484426F: free (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==260432== by 0x4AA8850: g_list_remove (glist.c:603)
==260432== by 0x158E42: client_calc_layer_recursive.isra.0 (client.c:2679)
==260432== by 0x12521A: UnknownInlinedFun (client.c:2699)
==260432== by 0x12521A: client_calc_layer (client.c:2729)
==260432== by 0x138170: event_process.lto_priv.0 (event.c:582)
==260432== by 0x48B3468: event_read (xqueue.c:338)
==260432== by 0x4AACAFA: UnknownInlinedFun (gmain.c:3460)
==260432== by 0x4AACAFA: g_main_context_dispatch (gmain.c:4200)
==260432== by 0x4B095D8: g_main_context_iterate.constprop.0 (gmain.c:4276)
==260432== by 0x4AAC0CE: g_main_loop_run (gmain.c:4479)
==260432== by 0x1194EF: main (openbox.c:382)
==260432== Block was alloc'd at
==260432== at 0x4841888: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==260432== by 0x4AB5829: g_malloc (gmem.c:130)
==260432== by 0x4AA755F: g_list_insert_before (glist.c:478)
==260432== by 0x151637: do_restack (stacking.c:100)
==260432== by 0x15280C: stacking_add_nonintrusive.part.0 (stacking.c:564)
==260432== by 0x158E77: UnknownInlinedFun (stacking.c:454)
==260432== by 0x158E77: client_calc_layer_recursive.isra.0 (client.c:2680)
==260432== by 0x125141: UnknownInlinedFun (client.c:2699)
==260432== by 0x125141: client_calc_layer (client.c:2717)
==260432== by 0x138170: event_process.lto_priv.0 (event.c:582)
==260432== by 0x48B3468: event_read (xqueue.c:338)
==260432== by 0x4AACAFA: UnknownInlinedFun (gmain.c:3460)
==260432== by 0x4AACAFA: g_main_context_dispatch (gmain.c:4200)
==260432== by 0x4B095D8: g_main_context_iterate.constprop.0 (gmain.c:4276)
==260432== by 0x4AAC0CE: g_main_loop_run (gmain.c:4479)
Comment by Ryan Farley (rcf) - Saturday, 18 March 2023, 05:24 GMT
There's now a fix on the upstream bug. Applying that (via the patch to the asp checkout I attached) managed to resolve the issue for an IRC user, at least.
Comment by Chih-Hsuan Yen (yan12125) - Saturday, 18 March 2023, 05:54 GMT
Thanks for the information. I pull the change from upstream github repo instead, as the commit message and comments provide some explanations.

The updated package openbox 3.6.1-10 is pushed to [community-testing]. Please test it and sign-off (if you have an archweb account) , thanks!
Comment by Chih-Hsuan Yen (yan12125) - Tuesday, 21 March 2023, 17:09 GMT
openbox 3.6.1-10 is moved to [community] after two users confirm it works [1]. There is a new patch submitted to the upstream issue, but an upstream dev does not consider it sufficient, so I'm not going to use that patch.

[1] https://bbs.archlinux.org/viewtopic.php?pid=2091124#p2091124

Loading...