Wnck.Screen.get_windows_stacked sometimes undefined
KDE users on Arch Linux report that Shutter crashes on launch with
Can't use an undefined value as an ARRAY reference at /usr/bin/shutter line 8384, <DATA> line 19.
see https://github.com/shutter-project/shutter/issues/659
The relevant code piece is:
my $wnck_screen;
if ($x11_supported) { # users are on X11, so this is true
$wnck_screen = Wnck::Screen::get_default();
$wnck_screen->force_update if $wnck_screen;
}
[...]
print $wnck_screen; # this gives: Wnck::Screen=HASH(0x6328ff5a05e0)
foreach my $win (@{$wnck_screen->get_windows_stacked}) { # this line gives the error
[...]
}
Tragically, this crash only appears randomly, so sometimes everything works as expected.
Please let me know, if you need further information! In the mean time, I will try to figure out if some update triggered the issue for the users.
Edited by Photon89