From 64de2dbed096e1aa58c4777c0c323e8403555ab0942d72efcfb10f9f46751f32 Mon Sep 17 00:00:00 2001 From: Stephan Kulow Date: Wed, 18 Jun 2014 05:50:28 +0000 Subject: [PATCH] Accepting request 236560 from GNOME:Apps - Fix crash when GST registry cache file is missing + add pidgin-crash-missing-gst-registry.patch according to the GST doc, "gst_init" should be called before any other calls. See (bnc#866455). See (pidgin.im#16224) for the upstream bug report. OBS-URL: https://build.opensuse.org/request/show/236560 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/pidgin?expand=0&rev=102 --- pidgin-crash-missing-gst-registry.patch | 29 +++++++++++++++++++++++++ pidgin.changes | 9 ++++++++ pidgin.spec | 3 +++ 3 files changed, 41 insertions(+) create mode 100644 pidgin-crash-missing-gst-registry.patch diff --git a/pidgin-crash-missing-gst-registry.patch b/pidgin-crash-missing-gst-registry.patch new file mode 100644 index 0000000..328eb73 --- /dev/null +++ b/pidgin-crash-missing-gst-registry.patch @@ -0,0 +1,29 @@ +diff --git a/pidgin/gtkmain.c b/pidgin/gtkmain.c +index 6e828fc..e690d58 100644 +--- a/pidgin/gtkmain.c ++++ b/pidgin/gtkmain.c +@@ -75,7 +75,7 @@ + #endif + + #include +- ++#include + + #ifdef HAVE_SIGNAL_H + +@@ -523,7 +523,15 @@ int main(int argc, char *argv[]) + #endif + + /* Initialize GThread before calling any Glib or GTK+ functions. */ ++#if !GLIB_CHECK_VERSION(2, 32, 0) ++ /* GLib threading system is automaticaly initialized since 2.32. ++ * For earlier versions, it have to be initialized before calling any ++ * Glib or GTK+ functions. ++ */ + g_thread_init(NULL); ++#endif ++ /* make sure Gst is initialized before any other Glib/Gst calls (see Gst docs) */ ++ gst_init(NULL, NULL); + + g_set_prgname("Pidgin"); + diff --git a/pidgin.changes b/pidgin.changes index fd64e90..580f310 100644 --- a/pidgin.changes +++ b/pidgin.changes @@ -1,3 +1,12 @@ +------------------------------------------------------------------- +Fri Mar 28 11:50:49 UTC 2014 - cxiong@suse.com + +- Fix crash when GST registry cache file is missing + + add pidgin-crash-missing-gst-registry.patch according to the + GST doc, "gst_init" should be called before any other calls. + See (bnc#866455). See (pidgin.im#16224) for the upstream bug + report. + ------------------------------------------------------------------- Mon Feb 3 13:15:03 UTC 2014 - zaitor@opensuse.org diff --git a/pidgin.spec b/pidgin.spec index 5a53a68..e5afbfb 100644 --- a/pidgin.spec +++ b/pidgin.spec @@ -46,6 +46,8 @@ Patch14: pidgin-mono-buildfix.patch Patch15: pidgin-fix-perl-build.patch # PATCH-FEATURE-UPSTREAM pidgin-gstreamer1.patch https://developer.pidgin.im/ticket/15386 dimstar@opensuse.org -- Port to GStreamer 1.0 Patch17: pidgin-gstreamer1.patch +# PATCH-FIX-UPSTREAM pidgin-crash-missing-gst-registry.patch bnc#866455 pidgin.im#16224 cxiong@suse.com -- fix crash when GST registry cache file is missing. +Patch18: pidgin-crash-missing-gst-registry.patch # Can use external libzephyr BuildRequires: cyrus-sasl-devel BuildRequires: dbus-1-devel @@ -402,6 +404,7 @@ translation-update-upstream %patch15 -p1 %if 0%{?suse_version} >= 1310 %patch17 -p1 +%patch18 -p1 %endif # Change Myanmar/Myanmar to Myanmar: