rpms/rhythmbox/devel rhythmbox-0.11.3-force-python-thread-init.patch, NONE, 1.1 rhythmbox.spec, 1.151, 1.152

Bastien Nocera (hadess) fedora-extras-commits at redhat.com
Fri Nov 30 14:03:17 UTC 2007


Author: hadess

Update of /cvs/pkgs/rpms/rhythmbox/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv23344

Modified Files:
	rhythmbox.spec 
Added Files:
	rhythmbox-0.11.3-force-python-thread-init.patch 
Log Message:
* Fri Nov 30 2007 - Bastien Nocera <bnocera at redhat.com> - 0.11.3-7
- Add patch to avoid crashing if no Python plugins are enabled by default
  (#393531)


rhythmbox-0.11.3-force-python-thread-init.patch:

--- NEW FILE rhythmbox-0.11.3-force-python-thread-init.patch ---
diff --git a/shell/main.c b/shell/main.c
index 71dde32..5d478fa 100644
--- a/shell/main.c
+++ b/shell/main.c
@@ -73,6 +73,10 @@
 #include "rb-playlist-manager.h"
 #include "rb-playlist-manager-glue.h"
 
+#ifdef ENABLE_PYTHON
+#include "rb-python-module.h"
+#endif
+
 #define HAVE_LIBGNOME_GOPTION defined(GNOME_PARAM_GOPTION_CONTEXT)
 
 static gboolean debug           = FALSE;
@@ -322,6 +326,15 @@ main (int argc, char **argv)
 
 		rb_profile_start ("mainloop");
 #ifdef ENABLE_PYTHON
+		{
+			/* force python etc. to be loaded.
+			 * otherwise, pyg_begin_allow_threads will crash,
+			 * and even if it didn't, we wouldn't be able to provide
+			 * thread safety for plugins loaded later on.
+			 */
+			GObject *z = g_object_new (RB_TYPE_PYTHON_MODULE, NULL);
+			g_object_unref (z);
+		}
 		pyg_begin_allow_threads;
 #endif
 		gtk_main ();


Index: rhythmbox.spec
===================================================================
RCS file: /cvs/pkgs/rpms/rhythmbox/devel/rhythmbox.spec,v
retrieving revision 1.151
retrieving revision 1.152
diff -u -r1.151 -r1.152
--- rhythmbox.spec	29 Nov 2007 01:02:08 -0000	1.151
+++ rhythmbox.spec	30 Nov 2007 14:02:43 -0000	1.152
@@ -3,7 +3,7 @@
 Name: rhythmbox
 Summary: Music Management Application 
 Version: 0.11.3
-Release: 6%{?dist}
+Release: 7%{?dist}
 License: GPLv2+ and GFDL+
 Group: Applications/Multimedia
 URL: http://www.gnome.org/projects/rhythmbox/
@@ -58,6 +58,8 @@
 Patch3: rhythmbox-0.11.3-add-missing-plugins-support.patch
 # http://bugzilla.gnome.org/show_bug.cgi?id=497430
 Patch4: rb-fix-broken-daap-playback.patch
+# http://bugzilla.gnome.org/show_bug.cgi?id=499208
+Patch5: rhythmbox-0.11.3-force-python-thread-init.patch
 
 %description
 Rhythmbox is an integrated music management application based on the powerful
@@ -92,6 +94,8 @@
 %patch2 -p0 -b .podcast
 %patch3 -p1 -b .missing-plugins
 %patch4 -p0 -b .broken-daap
+%patch5 -p1 -b .python-threading
+
 autoconf
 automake
 
@@ -205,6 +209,10 @@
 %{_libdir}/rhythmbox/plugins/upnp_coherence
 
 %changelog
+* Fri Nov 30 2007 - Bastien Nocera <bnocera at redhat.com> - 0.11.3-7
+- Add patch to avoid crashing if no Python plugins are enabled by default
+  (#393531)
+
 * Thu Nov 29 2007 - Bastien Nocera <bnocera at redhat.com> - 0.11.3-6
 - Remove stupid return that caused Podcasts never to be updated
   (see http://bugzilla.gnome.org/show_bug.cgi?id=500325)




More information about the fedora-extras-commits mailing list