GNOME Bugzilla – Bug 556729
Rhythmbox crashes if you try to import a directory which contains directories without execution permission
Last modified: 2018-05-24 13:42:48 UTC
this report has been filed here: https://bugs.edge.launchpad.net/ubuntu/+source/rhythmbox/+bug/284970 "Rhythmbox from 0.11.6svn20081008 crashes every time I try to import a directory if it contains other directories which haven't got the execution bit set; this is always reproducible until I "chmod +x" any such directories. Rhythmbox should ignore such directories instead and show a message about the error on the "Failed imports" tab." stacktrace: "Thread 8 (Thread 0xb5d53b90 (LWP 13107)):
+ Trace 208318
Thread 6 (Thread 0xb4b90b90 (LWP 13105))
Created attachment 121492 [details] [review] skip processing a file when g_file_enumerator_next_file fails
Looks like the error is causing rb_refstring_new to be called with child_uri=NULL from rhythmdb/rhythmdb.c file_info = g_file_enumerator_next_file (dir_enum, db->priv->exiting, &error); if (file_info == NULL && error == NULL) { /* done */ break; } child = g_file_get_child (dir, g_file_info_get_name (file_info)); child_uri = g_file_get_uri (child); ... result->real_uri = rb_refstring_new (child_uri); Attached patch will at least short-circuit that behavior.
I've committed something like your patch, but there's still more to do here. We should catch this at the directory level by doing an access check rather than at the file level, so we can report a useful error message.
-- 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/647.