GNOME Bugzilla – Bug 727551
Check use_count of GApplication in g_application_release()
Last modified: 2014-04-04 14:24:11 UTC
Created attachment 273538 [details] [review] Don't decrease use_count below 0 Since GApplication requires g_application_release() calls to be paired with calls of g_application_hold() it would be convenient to have an assert in g_application_release() which checks that use_count is higher than 0 before decreasing it. (see https://bugzilla.gnome.org/show_bug.cgi?id=727549 for additional info which led me to filing this bug) Attached patch adds such an assert. Regards Marek
Review of attachment 273538 [details] [review]: Thanks!
Comment on attachment 273538 [details] [review] Don't decrease use_count below 0 (In reply to comment #1) > Review of attachment 273538 [details] [review]: > > Thanks! Thank you for the review. I've pushed the patch to master, do you want me to push it also to a stable branch? Marek
It can't hurt -- go ahead.
Thanks, I've pushed it to glib-2-40 and glib-2-38.