GNOME Bugzilla – Bug 700398
Warn about detailed_action parameters
Last modified: 2018-05-24 15:18:52 UTC
Ubuntu just hit a problem in the messaging menu API on upgrade to the new GLib. They were using g_menu_item_new() with an action name string passed from the user. Thunderbird was using a string like 'http://something' as an action name, which tripped up the parser on the ':'. Even before the GLib change, the code would have broken if the action name provided by Thunderbird had a '::' in it, because there was never an intention of this API allowing the user to specify a target value for the action. APIs that take detailed action names (like ones in GMenu and GMenuItem) should contain warnings in their docs along the lines of "you should only use this function with a literal string action name -- otherwise use this other function". We should also consider adding _literal()-style versions of the API similar to the ones we have in GError (and for the same reason).
-- GitLab Migration Automatic Message -- This bug has been migrated to GNOME's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/glib/issues/702.