GNOME Bugzilla – Bug 636405
Add 'g_return_if_fail()' to 'g_settings_bind_with_mapping()'
Last modified: 2011-08-15 14:44:00 UTC
Hello! 'g_settings_bind_with_mapping()' doesn't check if passed 'object' isn't NULL. In result, when NULL is passed as 'object' argument to 'g_settings_bind()' (or directly to 'g_settings_bind_with_mapping()') we get segmentation fault. Simple 'g_return_if_fail (object!= NULL)' prevented from segmentation faults at this point.
While it may make sense to add some g_return_if_fail here, the fact that you're passing NULL is a bug in *your* code, and yours to fix.
commit 2b0171a8080c233f85c1d66fa6df6d75640b37e5 Author: Ryan Lortie <desrt@desrt.ca> Date: Mon Aug 15 10:42:35 2011 -0400 g_settings_bind: add some g_return checks https://bugzilla.gnome.org/show_bug.cgi?id=636405