[libgnome-keyring/f14/master] Fix an invalid assert checking pending calls (#660407, #665761)

Tomas Bzatek tbzatek at fedoraproject.org
Fri Mar 11 13:13:21 UTC 2011


commit c8ede9509f15d8c3fd861261fa0b93144f9f8163
Author: Tomas Bzatek <tbzatek at redhat.com>
Date:   Fri Mar 11 14:13:16 2011 +0100

    Fix an invalid assert checking pending calls (#660407, #665761)

 libgnome-keyring-2.91.93-operation-assert.patch |   26 +++++++++++++++++++++++
 libgnome-keyring.spec                           |   11 ++++++++-
 2 files changed, 35 insertions(+), 2 deletions(-)
---
diff --git a/libgnome-keyring-2.91.93-operation-assert.patch b/libgnome-keyring-2.91.93-operation-assert.patch
new file mode 100644
index 0000000..37d1049
--- /dev/null
+++ b/libgnome-keyring-2.91.93-operation-assert.patch
@@ -0,0 +1,26 @@
+From 84103a1d29e66ede966874e4af4b17706605cd48 Mon Sep 17 00:00:00 2001
+From: Stef Walter <stefw at collabora.co.uk>
+Date: Thu, 10 Mar 2011 16:12:23 +0000
+Subject: This assertion is vulnerable to corner conditions.
+
+In particular if the operation completes one pending call, unrefs it
+and creates another pending call, and the memory allocator decides
+to allocate that same memory for the next pending call, then this
+will assert in a bogus way.
+
+https://bugzilla.redhat.com/show_bug.cgi?id=660407
+---
+diff --git a/library/gkr-operation.c b/library/gkr-operation.c
+index 7600cd7..0fbba4d 100644
+--- a/library/gkr-operation.c
++++ b/library/gkr-operation.c
+@@ -404,7 +404,6 @@ gkr_operation_block_and_unref (GkrOperation *op)
+ 			if (op->pending == pending) {
+ 				g_return_val_if_fail (dbus_pending_call_get_completed (pending), BROKEN);
+ 				on_pending_call_notify (pending, op);
+-				g_assert (op->pending != pending);
+ 			}
+ 		} else if (op->prompting) {
+ 			dbus_connection_flush (op->conn);
+--
+cgit v0.8.3.4
diff --git a/libgnome-keyring.spec b/libgnome-keyring.spec
index 8f20465..f92f670 100644
--- a/libgnome-keyring.spec
+++ b/libgnome-keyring.spec
@@ -5,20 +5,23 @@
 Summary: Framework for managing passwords and other secrets
 Name: libgnome-keyring
 Version: 2.32.0
-Release: 1%{?dist}
+Release: 2%{?dist}
 License: GPLv2+ and LGPLv2+
 Group: System Environment/Libraries
 #VCS: git:git://git.gnome.org/libgnome-keyring
 Source: http://download.gnome.org/sources/libgnome-keyring/2.32/libgnome-keyring-%{version}.tar.bz2
 URL: http://live.gnome.org/GnomeKeyring
 
+# gkr_operation_block_and_unref(): assertion failed: (op->pending != pending)
+# https://bugzilla.gnome.org/show_bug.cgi?id=644407
+Patch0: libgnome-keyring-2.91.93-operation-assert.patch
+
 BuildRequires: glib2-devel >= %{glib2_version}
 BuildRequires: dbus-devel >= %{dbus_version}
 BuildRequires: libgcrypt-devel >= %{gcrypt_version}
 BuildRequires: intltool
 Conflicts: gnome-keyring < 2.29.4
 
-
 %description
 gnome-keyring is a program that keep password and other secrets for
 users. The library libgnome-keyring is used by applications to integrate
@@ -39,6 +42,7 @@ header files needed to develop applications that use libgnome-keyring.
 
 %prep
 %setup -q -n libgnome-keyring-%{version}
+%patch0 -p1 -b .op-assert
 
 
 %build
@@ -77,6 +81,9 @@ rm $RPM_BUILD_ROOT%{_libdir}/*.la
 
 
 %changelog
+* Fri Mar 11 2011 Tomas Bzatek <tbzatek at redhat.com> - 2.32.0-2
+- Fix an invalid assert checking pending calls (#660407, #665761)
+
 * Mon Sep 28 2010 Matthias Clasen <mclasen at redhat.com> - 2.32.0-1
 - Update to 2.32.0
 


More information about the scm-commits mailing list