After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 749420 - Clutter-WARNING **: clutter-actor.c:9912: Actor 'StWidget' tried to allocate a size of 0,00 x -2,00
Clutter-WARNING **: clutter-actor.c:9912: Actor 'StWidget' tried to allocate ...
Status: RESOLVED FIXED
Product: clutter
Classification: Platform
Component: ClutterActor
1.22.x
Other Windows
: Normal normal
: ---
Assigned To: clutter-maint
clutter-maint
Depends on:
Blocks:
 
 
Reported: 2015-05-15 10:39 UTC by Christian Stadelmann
Modified: 2016-04-26 10:28 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
attachment generated by `(gdb) set logging file/on` (64.53 KB, text/x-log)
2015-05-15 10:39 UTC, Christian Stadelmann
  Details
actor: Guard against negative-sized allocations (1.70 KB, patch)
2015-05-15 11:42 UTC, Emmanuele Bassi (:ebassi)
none Details | Review

Description Christian Stadelmann 2015-05-15 10:39:21 UTC
Created attachment 303411 [details]
attachment generated by `(gdb) set logging file/on`

I am running gnome-shell 3.16.1 on Fedora 22. I often get these warnings in syslog:

gnome-session[11035]: (gnome-shell:11161): Clutter-WARNING **: clutter-actor.c:9912: Actor 'StWidget' tried to allocate a size of 0,00 x -2,00

So I tried to find out what happened. This bug seems to be triggered (but not reliably reproducible in 100% of tries) by
a) either moving the mouse cursor to top left edge which should enter activities overview
b) closing a window from activities overview

Since st_widget_allocate() calls clutter_layout_manager_allocate in st-widget.c:417 with sane arguments (a ClutterLayoutManager, a Container, a ClutterActorBox with x1=0, y1=0, x2=0 and y2=0 and a flag CLUTTER_ABSOLUTE_ORIGIN_CHANGED) this looks like a bug in clutter to me. Feel free to reassign, I'm not sure about this.

I attached two full backtraces generated by gdb using the steps "Second" in https://wiki.gnome.org/Projects/GnomeShell/Debugging and running `gdb /usr/bin/gnome-shell`
Comment 1 Emmanuele Bassi (:ebassi) 2015-05-15 11:12:59 UTC
Does the StWidget actor have a margin? That's the only thing I can think of that may subtract from a 0x0 size.
Comment 2 Emmanuele Bassi (:ebassi) 2015-05-15 11:31:50 UTC
Actually, no: scratch that. Margin adjustments are already 0-sized safe.

It seems the culprit is clutter_actor_allocate_align_fill().
Comment 3 Emmanuele Bassi (:ebassi) 2015-05-15 11:42:23 UTC
Created attachment 303419 [details] [review]
actor: Guard against negative-sized allocations

The allocate_align_fill() method may end up trying to allocate an actor
with a negative size, due to rounding and floating point operations.
Comment 4 Emmanuele Bassi (:ebassi) 2015-05-15 11:47:18 UTC
It would be nice if you could test the attached patch.
Comment 5 Christian Stadelmann 2015-05-15 13:37:46 UTC
I was using clutter 1.22.0 before to create the backtraces.
This issue is still present with your patch applied to clutter 1.22.2 (update landed). Since I have not found a way to reliably reproduce I can't even tell it happens less often.
Comment 6 Christian Stadelmann 2016-04-26 10:28:45 UTC
I haven't seen this issue any more on Gnome 3.20 release with clutter 1.26 installed.