GNOME Bugzilla – Bug 790586
Rhythmbox crashes with SIGSEGV while launching through browser
Last modified: 2018-05-24 19:36:35 UTC
This happens when rhythmbox is launched as default app ( via firefox ) and repeating them for more audio files ( which downloads them to the same temporary location /tmp/mozilla_dev0 ). Downstream ubuntu bug: https://bugs.launchpad.net/ubuntu/+source/rhythmbox/+bug/1725826/comments/10
Created attachment 364021 [details] [review] rhythmdb: fix crash while opening songs via browser
The issue here is that, we start monitoring the temporary directory used by the browser ( /tmp/mozilla_dev0 for firefox ) and land up in directory change callback ( triggered by subsequent downloads ), even before library_locations is initialized. One quick question was, why would we monitor /tmp/mozilla_dev0, if we're going to ignore everything outside of dirs in library_locations[].
(In reply to gkrithi8 from comment #2) > The issue here is that, we start monitoring the temporary directory used by > the browser ( /tmp/mozilla_dev0 for firefox ) and land up in directory > change callback ( triggered by subsequent downloads ), even before > library_locations is initialized. So library_locations should be initialized earlier. > One quick question was, why would we monitor /tmp/mozilla_dev0, if we're > going to ignore everything outside of dirs in library_locations[]. Created files get ignored, changes and deletions of files that are in the library do not get ignored.
Review of attachment 364021 [details] [review]: This isn't the right approach.
okay
Was thinking of replacing the following line in rhythmdb.c: g_timeout_add_seconds (10, (GSourceFunc) rhythmdb_sync_library_idle, db); with one of the following: 1. Add a g_idle_add (rhythmdb_sync_library_idle) -or- g_idle_add_full(rhythmdb_sync_library_idle) with G_PRIORITY_HIGH_IDLE 2. Spawn a g_thread immediately to complete the task. thoughts ?
I don't think there's any reason to do that. The delay is deliberate, it's meant to keep the io and mainloop churn from monitoring separate from the library loading process. 10+ years ago when it was added, it made a noticeable difference. What I'm suggesting is just reading the library locations from gsettings earlier.
Created attachment 364501 [details] [review] rhythmdb: fix crash while opening songs via browser We start monitoring the temporary directory used by the browser ( /tmp/mozilla_dev0 for firefox ) and land up in directory change callback ( triggered by subsequent downloads ), even before "library_locations" is initialized. So, we initialize "library_locations" earlier.
-- 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/rhythmbox/issues/1610.