#1143872 cinnamon-screensaver: crashes with pygobject 3.57.0

Package:
cinnamon-screensaver
Source:
cinnamon-screensaver
Description:
Cinnamon screen saver and locker
Submitter:
Christoph Anton Mitterer
Date:
2026-08-08 20:25:05 UTC
Severity:
normal
Tags:
#1143872#5
Date:
2026-08-07 15:00:08 UTC
From:
To:
Hey.

Since upgrading to 3.57.0-2, whenever I lock cinnamon via cinnamon-screensaver,
and then unlock it,... it crashes after entering the password, apparently
showing some built-in fallback (which still keeps X locked), and instructs one
to go to th kernel console, log in and unlock via cinnamon-unlock-desktop).

At the same time I get a segfault:
Aug 07 16:51:43 heisenberg kernel: cs-backup-locke[2624494]: segfault at 0 ip 00007fa1d3c600cd sp 00007fff6fea5008 error 4 in libgio-2.0.so.0.8800.3[580cd,7fa1d3c46000+122000] likely on CPU 8 (core 16, socket 0)
Aug 07 16:51:43 heisenberg kernel: Code: 01 00 00 48 8d 35 a9 b8 10 00 48 8d 3d b0 ae 10 00 e8 e7 74 fe ff 0f 1f 80 00 00 00 00 f3 0f 1e fa 48 85 ff 74 0a 48 8b 47 18 <8b> 10 85 d2 74 05 c3 0f 1f 40 00 41 57 41 56 55 53 48 89 fb 48 83


Downgrading python3-gi to 3.56.3-2 fixes the issue.

Thanks,
Chris.

#1143872#10
Date:
2026-08-07 16:06:45 UTC
From:
To:
Control: severity -1 serious
Control: retitle -1 python3-gi: Triggers crash in cinnamon-screensaver

Thank you for taking the time to report this issue promptly. Please
additionally report this issue to the cinnamon maintainers in Debian
and upstream.

We were aware of one crash triggered by the new pygobject version, but
it was determined to be a downstream issue. Maybe the Cinnamon bug has
a similar cause.
https://gitlab.gnome.org/GNOME/pygobject/-/work_items/764

We can temporarily hold the new pygobject in Unstable to allow
maintainers time to fix the issue so I upgraded this bug to RC. We
prefer that the delay last days instead of weeks though.

On behalf of the Debian GNOME team,
Jeremy Bícha

#1143872#29
Date:
2026-08-07 21:07:33 UTC
From:
To:
Hello,

Bug #1143872 in cinnamon-screensaver reported by you has been fixed in the
Git repository and is awaiting an upload. You can see the commit
message below and you can check the diff of the fix at:

https://salsa.debian.org/cinnamon-team/cinnamon-screensaver/-/commit/eaefdf39f7261bfe5dcc63190baad8e2d0b093fc
------------------------------------------------------------------------
d/patches: fix unlock failing with pygobject 3.57

Two patches, both sent upstream (issue #507), verified on a Debian sid
VM with python3-gi 3.57.0.

manager.py-Fix-unlocking-with-pygobject-3.57.patch: since pygobject
3.57.0 GLib.Pid is no longer an int subclass, so `if self.fb_pid > 0` in
kill_fallback_window() raises TypeError and aborts unlock() halfway.
cs-backup-locker is never told to quit while the stage window is already
gone, so the backup locker grabs the screen: entering the correct
password leaves the user with "Something went wrong with the
screensaver" and the desktop still locked.

backup-locker-Fix-use-after-free-of-the-window-monitor-ca.patch:
cs-backup-locker unreffed the borrowed GCancellable returned by
g_task_get_cancellable(), so quit() later called g_cancellable_cancel()
on freed memory and segfaulted. Latent since 5.6.1, only reachable when
the main process dies first - which is what the patch above was causing.

Closes: #1143872

Assisted-by: Claude Code:claude-opus-5
------------------------------------------------------------------------

(this message was generated automatically)
-- 
Greetings

https://bugs.debian.org/1143872

#1143872#36
Date:
2026-08-07 21:19:20 UTC
From:
To:
Thanks for the report. I could reproduce it on a Debian sid VM (cinnamon
6.6.9, cinnamon-screensaver 6.6.1-1, python3-gi 3.57.0-2, glib 2.88.3-2) and
there are actually two distinct bugs involved.

1) The failure you see is a Python exception, not a crash of the main
process. Running the screensaver with --debug shows:

Traceback (most recent call last):
   File "/usr/share/cinnamon-screensaver/stage.py", line 647, in
authentication_result_callback
     self.manager.unlock()
   File "/usr/share/cinnamon-screensaver/manager.py", line 104, in unlock
     self.set_locked(False)
   File "/usr/share/cinnamon-screensaver/manager.py", line 73, in set_locked
     self.kill_fallback_window()
   File "/usr/share/cinnamon-screensaver/manager.py", line 309, in
kill_fallback_window
     if self.fb_pid > 0:
TypeError: '>' not supported between instances of 'Pid' and 'int'

Up to pygobject 3.56.3, GLib.Pid was gi._gi.Pid, a C type deriving from int.
Since 3.57.0 (upstream commit b6e14902, "Reimplement GLib.spawn_async in
Python") it is a plain Python class implementing only __int__() and close():
no __index__, no comparisons with integers. manager.py stores the result of
GLib.spawn_async() in self.fb_pid, so both `self.fb_pid > 0` and
os.kill(self.fb_pid, ...) now fail.

The exception aborts unlock() before cs-backup-locker is sent its SIGTERM,
but the stage window is destroyed anyway - so the backup locker grabs the
screen and you get "Something went wrong with the screensaver" with the
desktop still locked. That matches your description exactly.

2) The segfault you reported is a second, independent bug in
cs-backup-locker
itself, latent since 5.6.1. I disassembled the crash address against
libglib2.0-0t64 2.88.3-2 and got a coredump backtrace confirming it:

   #0  g_cancellable_cancel (libgio-2.0.so.0 + 0x580cd)
   #1  quit (cs-backup-locker + 0x5109)
   #2  g_main_dispatch
   #3  g_main_context_dispatch_unlocked
   #4  g_main_loop_run
   #5  gtk_main
   #6  main

screensaver_window_gone() calls g_clear_object() on the GCancellable
returned
by g_task_get_cancellable(), which is (transfer none) - it drops a reference
the process never owned. Once the GTask is finalized the cancellable is
freed, and quit() then cancels a dangling pointer. It is only reachable when
the main screensaver process dies first: on a normal unlock the SIGTERM
arrives before the screensaver window disappears, so that callback never
runs. Which is why it surfaced together with bug 1.

Both are fixed by the patches sent upstream in
https://github.com/linuxmint/cinnamon-screensaver/pull/508 and verified on
the same VM: unlocking works again, and forcing the crash path with the
first
patch reverted no longer produces a SIGSEGV.

Note that int() around GLib.spawn_async() is safe on older pygobject too,
since GLib.Pid used to be an int - checked against 3.48.2 (Ubuntu 24.04),
3.50.0 (trixie) and 3.57.0 (sid).

#1143872#43
Date:
2026-08-08 20:23:59 UTC
From:
To:
We believe that the bug you reported is fixed in the latest version of
cinnamon-screensaver, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 1143872@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Fabio Fantoni <fantonifabio@tiscali.it> (supplier of updated cinnamon-screensaver package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@ftp-master.debian.org)
Format: 1.8
Date: Sat, 08 Aug 2026 21:46:42 +0200
Source: cinnamon-screensaver
Built-For-Profiles: noudeb
Architecture: source
Version: 6.6.1-2
Distribution: unstable
Urgency: medium
Maintainer: Debian Cinnamon Team <debian-cinnamon@lists.debian.org>
Changed-By: Fabio Fantoni <fantonifabio@tiscali.it>
Closes: 1136478 1143872
Changes:
 cinnamon-screensaver (6.6.1-2) unstable; urgency=medium
 .
   * d/patches:
     - fix unlock failing with pygobject 3.57 (Closes: #1143872)
     - backup-locker: Fix use-after-free of the window monitor cancellable
   * d/control: add procps to Depends (Closes: #1136478)
Checksums-Sha1:
 843d829070766265820480ea792bd2bc6ab50420 2509 cinnamon-screensaver_6.6.1-2.dsc
 941bc786827f359271ba9e5d46d31e99888b526e 145004 cinnamon-screensaver_6.6.1.orig.tar.gz
 6ca188c5fbfcfd74893d90091794d528fbe47c8e 10852 cinnamon-screensaver_6.6.1-2.debian.tar.xz
 91b1ca6b93818e569d96e8b5e6016df41d7d0e1d 8709 cinnamon-screensaver_6.6.1-2_source.buildinfo
Checksums-Sha256:
 f6242ebba5df930cef11834860a28f89d8c0ed64a8bfba8bfbf6e1d20b3e4af4 2509 cinnamon-screensaver_6.6.1-2.dsc
 6f03ed07c44a780a66384b5a3cb39a2ecdfbe3fd092b193dc6fc0823994d3ece 145004 cinnamon-screensaver_6.6.1.orig.tar.gz
 e855352d182cb209f4b069d8f6b08b2e353a6e156cc0eaeec3db57e7cdf8c523 10852 cinnamon-screensaver_6.6.1-2.debian.tar.xz
 026cde077f91676c5a21455e1f0ac6022a2bc3bb83d69a9c25c4f588abb46b7b 8709 cinnamon-screensaver_6.6.1-2_source.buildinfo
Files:
 4eab76b138e1fd72c0a1d3050af3d5d2 2509 x11 - cinnamon-screensaver_6.6.1-2.dsc
 05b25cf7cf58eee5798ca839380579d4 145004 x11 - cinnamon-screensaver_6.6.1.orig.tar.gz
 b927f6dcdc62be0182a37889d3e973d2 10852 x11 - cinnamon-screensaver_6.6.1-2.debian.tar.xz
 aeec116e8c262accd431fd42cd3b87d9 8709 x11 - cinnamon-screensaver_6.6.1-2_source.buildinfo
-----BEGIN PGP SIGNATURE-----

iQIzBAEBCgAdFiEELEHRfLe4S9D5+1GzaAZorpB/EB0FAmp3h+wACgkQaAZorpB/
EB1nuw/8D19M/wEI5gLhQiUCNsQtcuL7xo6Z5IrfcJFu9ZnREFfsTpYlZLIsTveE
9DnOEH2UOyAwztRlv/U7quhhuewifRT4Fm6xnOEZMPKcUb2t2Bl10DbFVbc8L231
f1NoiVoA/5T1FvCyr6iLYZmuNSLQHMzOsYmQdKX+A6qzDUFRQDMJNod3wJovl8rx
bqso0uK6e8j3AF7IB1FTAhPk2rDTbw0Jd7bTOMsDI00kydCinhumwSUAZ4Z7zjq7
QfSHXGTPGzWQsPrxYPwAxgTh+H27/GFal89HvMEGZfw44ovXQQ9OQmG1aZGwI6g3
XPwWFmGw38STsbLvKd9As/6OJZ0wwChnMnxtw9rQiqF8Hz6A7Sh1WBftVpRyiv60
XmnL1QTLsuncHz/0ld9NgAVN1rqnqFNk2f3m7zOUbzc4Vmt2GdxvLvnqQYfdFOZq
7DcQ0JGEuk1heZUapkViX2YMUQgThR6hELT3xwri4Sa11tMEue1LUQr93pMnKAlP
1tFFE3yzUQVv/ot05TubjIFVK6cPshITPnj7mfbyfIMRkSLl0Bcl5mMHqq7PQPQt
9q9fZs6NNQIKymA/51x+qHKCHWuB9L6Kvlzc1rA8uvsq+A1Bvq6yDlxtdfMUZ+Yc
9umQ5jE32xxycH9s0XEMBFlr+eSapdzI9aRT9/dC/XBATMVXAKI=
=orEm
-----END PGP SIGNATURE-----