[Pkg-cli-libs-commits] [gtk-sharp2] 01/01: Add patches from upstream for #776145

Simon McVittie smcv at debian.org
Sun Feb 22 14:07:52 UTC 2015


This is an automated email from the git hooks/post-receive script.

smcv pushed a commit to branch master
in repository gtk-sharp2.

commit b2210fe98d5fc7a3d0825481cc164a4b5319c3fb
Author: Simon McVittie <smcv at debian.org>
Date:   Sat Feb 21 11:53:02 2015 +0000

    Add patches from upstream for #776145
    
    debian/patches: add upstream commits
    0001-glib-Fix-native-GLib-warnings-when-disposing-SourceP,
    0002-Check-that-source_handlers-contains-the-tag from version 2.12.26,
    fixing warning spam from removing nonexistent event sources with
    recent GLib. This was filed as RC, since it can consume significant
    disk space in long-running Gtk# apps. (Closes: #776145)
---
 debian/changelog                                   | 12 +++++++
 ...tive-GLib-warnings-when-disposing-SourceP.patch | 42 ++++++++++++++++++++++
 ...eck-that-source_handlers-contains-the-tag.patch | 24 +++++++++++++
 debian/patches/series                              |  3 +-
 4 files changed, 80 insertions(+), 1 deletion(-)

diff --git a/debian/changelog b/debian/changelog
index aa7eac2..36806c3 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,15 @@
+gtk-sharp2 (2.12.10-5.1) unstable; urgency=medium
+
+  * Non-maintainer upload.
+  * debian/patches: add upstream commits
+    0001-glib-Fix-native-GLib-warnings-when-disposing-SourceP,
+    0002-Check-that-source_handlers-contains-the-tag from version 2.12.26,
+    fixing warning spam from removing nonexistent event sources with
+    recent GLib. This was filed as RC, since it can consume significant
+    disk space in long-running Gtk# apps. (Closes: #776145)
+
+ -- Simon McVittie <smcv at debian.org>  Sat, 21 Feb 2015 11:52:55 +0000
+
 gtk-sharp2 (2.12.10-5) unstable; urgency=low
 
   * [b130b4f] debian/patches: add 06_IconTheme_use_glib_marshaller.
diff --git a/debian/patches/0001-glib-Fix-native-GLib-warnings-when-disposing-SourceP.patch b/debian/patches/0001-glib-Fix-native-GLib-warnings-when-disposing-SourceP.patch
new file mode 100644
index 0000000..e3f7b67
--- /dev/null
+++ b/debian/patches/0001-glib-Fix-native-GLib-warnings-when-disposing-SourceP.patch
@@ -0,0 +1,42 @@
+From: Bertrand Lorentz <bertrand.lorentz at gmail.com>
+Date: Sat, 5 Jul 2014 15:52:56 +0200
+Subject: [PATCH 1/2] glib: Fix native GLib warnings when disposing SourceProxy
+ objects
+
+When an instance of SourceProxy was finalized, we would try to remove
+the corresponding source, even if it was already removed. This now
+causes native GLib to print out warnings because it can't find the
+source ID.
+
+Now Source.Remove only calls g_source_remove if we really had a handler
+registered for the ID we're removing.
+
+Origin: upstream, 2.12.26, commit:3a01260d87c738361f1b72673f73135b4d7545e7
+Bug-Debian: https://bugs.debian.org/776145
+---
+ glib/Source.cs | 12 +++++++++---
+ 1 file changed, 9 insertions(+), 3 deletions(-)
+
+diff --git a/glib/Source.cs b/glib/Source.cs
+index b62c3c5..89e691f 100644
+--- a/glib/Source.cs
++++ b/glib/Source.cs
+@@ -54,9 +54,15 @@ namespace GLib {
+ 
+ 		public static bool Remove (uint tag)
+ 		{
+-			lock (Source.source_handlers)
+-				source_handlers.Remove (tag);
+-			return g_source_remove (tag);
++			// g_source_remove always returns true, so we follow that
++			bool ret = true;
++
++			lock (Source.source_handlers) {
++				if (source_handlers.Remove (tag)) {
++					ret = g_source_remove (tag);
++				}
++			}
++			return ret;
+ 		}
+ 	}
+ }
diff --git a/debian/patches/0002-Check-that-source_handlers-contains-the-tag.patch b/debian/patches/0002-Check-that-source_handlers-contains-the-tag.patch
new file mode 100644
index 0000000..a0794fd
--- /dev/null
+++ b/debian/patches/0002-Check-that-source_handlers-contains-the-tag.patch
@@ -0,0 +1,24 @@
+From: Cody Russell <cody at jhu.edu>
+Date: Fri, 11 Jul 2014 09:51:53 -0500
+Subject: [PATCH 2/2] Check that source_handlers contains the tag.
+
+Origin: upstream, 2.12.26, commit:9c78f7019c8622a3fc7a10c3d3dc8dcb5f44a289
+Bug-Debian: https://bugs.debian.org/776145
+---
+ glib/Source.cs | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/glib/Source.cs b/glib/Source.cs
+index 89e691f..cf9f4ba 100644
+--- a/glib/Source.cs
++++ b/glib/Source.cs
+@@ -58,7 +58,8 @@ namespace GLib {
+ 			bool ret = true;
+ 
+ 			lock (Source.source_handlers) {
+-				if (source_handlers.Remove (tag)) {
++				if (source_handlers.Contains (tag)) {
++					source_handlers.Remove (tag);
+ 					ret = g_source_remove (tag);
+ 				}
+ 			}
diff --git a/debian/patches/series b/debian/patches/series
index 747de2b..0158d40 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -3,4 +3,5 @@
 04_fix_glib_2.31_threading
 05_glib_single_include
 06_IconTheme_use_glib_marshaller
-
+0001-glib-Fix-native-GLib-warnings-when-disposing-SourceP.patch
+0002-Check-that-source_handlers-contains-the-tag.patch

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-cli-libs/packages/gtk-sharp2.git



More information about the Pkg-cli-libs-commits mailing list