After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 585690 - Xrandr: GLib-CRITICAL **: g_propagate_error: assertion `src != NULL' failed
Xrandr: GLib-CRITICAL **: g_propagate_error: assertion `src != NULL' failed
Status: RESOLVED NOTGNOME
Product: gnome-desktop
Classification: Core
Component: libgnome-desktop
unspecified
Other All
: Normal normal
: ---
Assigned To: Desktop Maintainers
Desktop Maintainers
Depends on:
Blocks:
 
 
Reported: 2009-06-13 22:42 UTC by Hernando Torque
Modified: 2009-12-19 03:20 UTC
See Also:
GNOME target: ---
GNOME version: 2.27/2.28


Attachments
debug output (6.30 KB, text/plain)
2009-06-13 22:43 UTC, Hernando Torque
Details
strace output (161.09 KB, text/plain)
2009-06-13 22:45 UTC, Hernando Torque
Details
backtrace (1.09 KB, text/plain)
2009-06-13 22:46 UTC, Hernando Torque
Details
critical warnings after touching missing files (3.18 KB, text/plain)
2009-06-14 17:47 UTC, Hernando Torque
Details

Description Hernando Torque 2009-06-13 22:42:04 UTC
Please describe the problem:
Starting gnome-settings-daemon leads to following log message (repeated once):

(gnome-settings-daemon:4029): GLib-CRITICAL **: g_propagate_error: assertion `src != NULL' failed

The output of "g-s-d --no-daemon --debug" (attached) indicates that the xrandr plugin might be the culprit.

Also attached: strace output, full backtrace (one function shwoing '??' might be maybe_activate_plugin() - had no idea which debug symbols were missing).

Steps to reproduce:


Actual results:


Expected results:


Does this happen every time?


Other information:
Launchpad bug report: https://bugs.launchpad.net/ubuntu/+source/gstreamer0.10/+bug/384439

Strace output also made me find this bug report: http://bugzilla.gnome.org/show_bug.cgi?id=565785 but I'm not sure if there is a connection.
Comment 1 Hernando Torque 2009-06-13 22:43:50 UTC
Created attachment 136523 [details]
debug output
Comment 2 Hernando Torque 2009-06-13 22:45:03 UTC
Created attachment 136524 [details]
strace output
Comment 3 Hernando Torque 2009-06-13 22:46:23 UTC
Created attachment 136525 [details]
backtrace
Comment 4 Jens Granseuer 2009-06-14 09:10:06 UTC
That seems to indicate a problem in gnome-desktop. It looks like one of the functions called by g-s-d (something called by gnome_rr_config_apply_from_filename) returns FALSE without initializing the error passed to it. I guess it'd be useful if you could step through to find out which one it is.
Comment 5 Hernando Torque 2009-06-14 11:23:52 UTC
Ubuntus patched gnome_rr_config_apply_from_filename function: http://paste.ubuntu.com/195593/ (error should also occur with the unpatched version).

*) gnome_rr_screen_refresh() returns FALSE, so the if-path is taken. 
*) 'my_error' is NULL so we skip to the desired filename test which fails, so the else-path is taken.
*) config_new_stored() then tries to read from 'filename' which doesn't exist and therefor returns NULL. 
*) finally gnome_rr_config_apply_from_filename returns FALSE with 'my_error' being uninitialized.

gnome_rr_screen_refresh() in gnome-rr.c passes 'my_error' to screen_update(), which passes it screen_info_new(), which passes it to fill_out_screen_info(), where it finally should be set.

As I don't know if 'my_screen' should even get initialized I haven't followed that road, but tell me if I should.
Comment 6 Hernando Torque 2009-06-14 11:34:43 UTC
Uhm, forget the last paragraph... (it should be 'my_error' and gnome_rr_config_apply_from_filename is called with an uninitialized error anyway - didn't get the concept right ;)).
Comment 7 Hernando Torque 2009-06-14 17:46:03 UTC
Me again: I touched the two non-existing files causing the warnings (~/.config/monitors.xml.backup and ~/.config/monitors.xml) and the g_propagate_error errors were gone but subsequent efforts to apply the configuration from those empty files threw three CRITICAL errors (see attachment).

First things first: is it ok that I don't have those two files? (I'm currently running Ubuntu 9.10 Alpha 2 with the 'vesa' video driver, if that's relevant.)
Comment 8 Hernando Torque 2009-06-14 17:47:03 UTC
Created attachment 136575 [details]
critical warnings after touching missing files
Comment 9 Hernando Torque 2009-07-07 10:21:54 UTC
Not a fix for the underlying problem but a way to stop the error messages:

*) Running "System > Preferences > Screen" and clicking on "Apply" created a valid file ~/.config/monitors.xml. That reduced the number of error messages from two to one (monitors.xml.backup still missing).

*) Copying monitors.xml to monitors.xml.backup made the error messages go away.
Comment 10 Federico Mena Quintero 2009-07-27 21:03:58 UTC
Does this error also happen without Ubuntu's patches?

The function you sent shows an Ubuntu patch based on an old version of the code in gnome-desktop --- in the new version, gnome_rr_config_apply_from_filename() is just a stub that calls gnome_rr_config_apply_from_filename_with_time().
Comment 11 Hernando Torque 2009-07-27 23:26:09 UTC
Yes, current sources used in Ubuntu are at 2.27.4 and I see that stub but I assume that it would also happen without patch since

stored = config_new_stored (screen, filename, error);

would still be called with the URL to a non-existent file (stored = 'NULL'). That will cause gnome_rr_config_apply_from_filename_with_time() to return 'FALSE' and therefor apply_configuration_from_filename() in gsd-xrandr-manager.c will cause the error.
Comment 12 Hernando Torque 2009-07-28 01:24:13 UTC
Ok, I downloaded Ubuntu's source code, removed the patch in question, used debuild to create the packages, installed them and did a session restart: no complaints.

So I guess this goes back to Launchpad?
Comment 13 Jens Granseuer 2009-07-28 07:12:18 UTC
Yes, please.
Comment 14 Thomas 2009-12-11 18:33:47 UTC
Hallo, 

In recent days I started to have problems with my gnome desktop session with
error messages like

GLib-CRITICAL **: g_propagate_error: assertion `src != NULL' failed

in my .xsession-errors. To make matters worse, it would cause my x session freeze. A restart or reload of the gdm daemon did not do any good. I had to reboot, which resulted in a files system check. This did not happen every time, but only every fourth boot or so.
I am running ubuntu jaunty.

I scanned bug reports a bit and reverted the 100_load_desired_settings.patch and rebuilt the package gnome-desktop and so far haven't seen the problem that panel applets would take several seconds to load and the session to freeze. Also the above assertion would vanish from .xsession-errors.

Can you clarify a bit?!

thomas
Comment 15 Thomas 2009-12-12 03:20:35 UTC
Nope, that did not solve it. Upgraded ubuntu to 9.10 instead, and haven't seen the problem yet, so far - after a couple of reboot's.
Comment 16 Thomas 2009-12-19 03:20:46 UTC
A final note. Maybe it's of help for people with similar problems. 
After I followed instructions on 
HOWTO: PulseAudio Fixes & System-Wide Equalizer Support, http://ubuntuforums.org/showthread.php?t=789578, 
I haven't had any hangs while booting up my machine so far, about a week.