! Please note that this is a snapshot of our old Bugzilla server, which is read only since May 29, 2020. Please go to gitlab.xfce.org for our new server !
settings_register_callback: assertion fails on startup
Status:
RESOLVED: FIXED
Product:
Xfdesktop
Component:
General

Comments

Description Rick 2008-02-21 20:03:09 CET
Running xfce 4.4.2 on FreeBSD 6.3, the following messages appear when xfce
starts.  Nevertheless, (almost) everything appears to work properly.

** (xfdesktop:2398): CRITICAL **: settings_register_callback: assertion `cb && u
ser_data && mcs_client' failed

** (xfdesktop:2398): CRITICAL **: settings_register_callback: assertion `cb && u
ser_data && mcs_client' failed


The following code is in settings.c.  Note the comment and assertion stating 
that user_data must not be NULL.

   126	/* callbacks are keyed to the user_data parameter, which can't be NULL.
   127	 * for each user_data parameter registered, each callback registered (there
   128	 * can be more than one) for that user_data pointer will be called until
   129	 * one of them returns TRUE. */
   130	void
   131	settings_register_callback(SettingsCallback cb, gpointer user_data)
   132	{
   133	    GList *l;
   134	    SettingsCBData *cbdata;
   135	    
   136	    g_return_if_fail(cb && user_data && mcs_client);


The following code is in main.c.

   384	    if(mcs_client) {
   385	        settings_register_callback(menu_settings_changed, NULL);
   386	        settings_register_callback(windowlist_settings_changed, NULL);
   387	    }

The user_data parameter is NULL, resulting in the error messages.
Comment 1 Brian J. Tarricone (not reading bugmail) 2008-02-21 20:08:38 CET
Boo, I fixed this on trunk; didn't realise it was present on 4.4 as well...  You can just put "desktops[0]" in place of those two NULLs in main.c; that should shut up the warnings an make settings work properly.  Should really fix this in a better way, but that's easiest and least risky.
Comment 2 Brian J. Tarricone (not reading bugmail) 2008-03-09 20:35:44 CET
*** Bug 3935 has been marked as a duplicate of this bug. ***

Bug #3863

Reported by:
Rick
Reported on: 2008-02-21
Last modified on: 2009-07-14
Duplicates (1):
  • 3935 ** (xfdesktop:2385): CRITICAL **: settings_register_callback: assertion `cb && user_data && mcs_client' failed

People

Assignee:
Brian J. Tarricone (not reading bugmail)
CC List:
1 user

Version

Attachments

Additional information