Skip to content

gs-screenshot-carousel: First ref_sink() img widget before discarding it

Milan Crha requested to merge wip/carousel-img-unref into main

As the GtkWidget is an object with a floating reference, there's needed to ref_sink() it forst before unreffing it with g_object_unref(), otherwise there is a runtime warning on the console:

16:42:50:751 Gtk A floating object was finalized. This means that someone called g_object_unref() on an object that had only a floating reference; the initial floating reference is not owned by anyone and must be removed with g_object_ref_sink().

Merge request reports