2.99 (gimp-2.99:164): Gtk-CRITICAL **: 21:24:59.975: gtk_application_uninhibit: assertion 'cookie > 0' failed
Environment/Versions
- GIMP version: latest, 2.99.19
- Package: self-built
- Operating System: Linux
Description of the bug
In the console, message as above, no apparent harm, happens when closing app.
Reproduction
Is the bug reproducible? Yes
Reproduction steps:
- Open wilber.png
- Close the app
Expected result: no warning
Actual result: warning
Additional information
(gdb) bt
#0 0x00007ffff7973a0d in g_logv () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#1 0x00007ffff7973ca3 in g_log () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#2 0x0000555555a04f41 in gui_inhibit (gimp=0x5555561641f0) at ../gimp/app/gui/gui-vtable.c:1023
#3 0x0000555555a051c9 in gui_image_disconnect (image=0x5555594694d0, gimp=0x5555561641f0) at ../gimp/app/gui/gui-vtable.c:1091
#4 0x00007ffff7a6d130 in g_closure_invoke () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#5 0x00007ffff7a9a819 in ??? () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#6 0x00007ffff7a8b9b1 in ??? () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#7 0x00007ffff7a8bbd6 in g_signal_emit_valist () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#8 0x00007ffff7a8bc93 in g_signal_emit () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#9 0x0000555555715cf8 in gimp_object_dispose (object=0x5555594694d0) at ../gimp/app/core/gimpobject.c:149
#10 0x00005555556e7119 in gimp_image_dispose (object=0x5555594694d0) at ../gimp/app/core/gimpimage.c:1143
#11 0x00007ffff7a7ad50 in g_object_unref () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#12 0x0000555555c91ddf in gimp_display_set_image (display=0x55555609a170, image=0x0) at ../gimp/app/display/gimpdisplay.c:621
#13 0x0000555555c922d6 in gimp_display_delete (display=0x55555609a170) at ../gimp/app/display/gimpdisplay.c:468
#14 0x0000555555c90bca in gimp_displays_delete (gimp=0x5555561641f0) at ../gimp/app/display/gimpdisplay-foreach.c:164
#15 0x00005555559fa65f in gui_exit_callback (gimp=0x5555561641f0, force=0) at ../gimp/app/gui/gui.c:710
#16 0x000055555573a6d0 in gimp_marshal_BOOLEAN__BOOLEAN
(closure=0x555556548390, return_value=0x7fffffffd720, n_param_values=2, param_values=0x7fffffffd7b0, invocation_hint=0x7fffffffd700, marshal_data=0x0)
at app/core/gimpmarshal.c:84
#17 0x00007ffff7a6d130 in g_closure_invoke () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#18 0x00007ffff7a9a4ac in ??? () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#19 0x00007ffff7a8b312 in ??? () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#20 0x00007ffff7a8bbd6 in g_signal_emit_valist () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#21 0x00007ffff7a8bc93 in g_signal_emit () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#22 0x000055555569dbdd in gimp_exit (gimp=0x5555561641f0, force=0) at ../gimp/app/core/gimp.c:902
#23 0x0000555555c1101c in file_quit_cmd_callback (action=0x5555583b30e0, value=0x0, data=0x5555561641f0) at ../gimp/app/actions/file-commands.c:570
#24 0x00007ffff7a6d130 in g_closure_invoke () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#25 0x00007ffff7a9a4ac in ??? () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#26 0x00007ffff7a8b9b1 in ??? () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#27 0x00007ffff7a8bbd6 in g_signal_emit_valist () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#28 0x00007ffff7a8bc93 in g_signal_emit () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
Discussion
On the face of it, the code is wrong:
Gtk documentation says:
cookie
Type: guint
A cookie that was returned by gtk_application_inhibit().
but in gui-vtable.c line 1023 we are setting a var cookie to 0 and then passing it. So it is NOT a cookie that was returned by gtk_application_inhibit. Might be failing only when no images are dirty?