[PackageKit/f14] Backport a patch to fix failing the pretransaction check. Resolves #684464

Richard Hughes rhughes at fedoraproject.org
Thu Aug 4 10:58:54 UTC 2011


commit 67316b4e7cf2b0012d59b011d5e448551c3d8497
Author: Richard Hughes <richard at hughsie.com>
Date:   Thu Aug 4 11:58:45 2011 +0100

    Backport a patch to fix failing the pretransaction check.
    Resolves #684464

 PackageKit-0.6.15-fix-pretransaction-error.patch |   22 ++++++++++++++++++++++
 PackageKit.spec                                  |   10 +++++++++-
 2 files changed, 31 insertions(+), 1 deletions(-)
---
diff --git a/PackageKit-0.6.15-fix-pretransaction-error.patch b/PackageKit-0.6.15-fix-pretransaction-error.patch
new file mode 100644
index 0000000..47efe20
--- /dev/null
+++ b/PackageKit-0.6.15-fix-pretransaction-error.patch
@@ -0,0 +1,22 @@
+commit 11872c12358cb3ec1491c5309280f548d04aa00e
+Author: Richard Hughes <richard at hughsie.com>
+Date:   Tue Mar 15 11:08:58 2011 +0000
+
+    Fix a crash where the error code was pointing to freed memory. Fixes rh#684464
+
+diff --git a/src/pk-transaction.c b/src/pk-transaction.c
+index 5dd4577..34ded99 100644
+--- a/src/pk-transaction.c
++++ b/src/pk-transaction.c
+@@ -1874,8 +1874,9 @@ pk_transaction_set_running (PkTransaction *transaction)
+ 	/* set proxy */
+ 	ret = pk_transaction_set_session_state (transaction, &error);
+ 	if (!ret) {
+-		g_debug ("failed to set the session state (non-fatal): %s", error->message);
+-		g_error_free (error);
++		g_debug ("failed to set the session state (non-fatal): %s",
++			 error->message);
++		g_clear_error (&error);
+ 	}
+ 
+ 	/* we are no longer waiting, we are setting up */
diff --git a/PackageKit.spec b/PackageKit.spec
index 4dfef78..753fb3e 100644
--- a/PackageKit.spec
+++ b/PackageKit.spec
@@ -5,7 +5,7 @@
 Summary:   Package management service
 Name:      PackageKit
 Version:   0.6.12
-Release:   3%{?dist}
+Release:   4%{?dist}
 License:   GPLv2+ and LGPLv2+
 URL:       http://www.packagekit.org
 Source0:   http://www.packagekit.org/releases/%{name}-%{version}.tar.bz2
@@ -20,6 +20,9 @@ Patch1:    PackageKit-0.4.4-Fedora-turn-off-time.conf.patch
 # https://gitorious.org/packagekit/packagekit/commit/a32482c30d3760ed5a158d4cad7c1f2a569b49ae
 Patch2: PackageKit-qt_searchgroups.patch
 
+# upstream
+Patch3: PackageKit-0.6.15-fix-pretransaction-error.patch
+
 Requires: PackageKit-glib = %{version}-%{release}
 Requires: PackageKit-yum = %{version}-%{release}
 Requires: shared-mime-info
@@ -233,6 +236,7 @@ user to restart the computer or remove and re-insert the device.
 %patch0 -p1 -b .fedora
 %patch1 -p1 -b .no-time
 %patch2 -p1 -b .qt_searchgroups
+%patch3 -p1 -b .pretransaction-error
 
 %build
 %configure \
@@ -431,6 +435,10 @@ update-mime-database %{_datadir}/mime &> /dev/null || :
 %{_includedir}/PackageKit/backend/*.h
 
 %changelog
+* Thu Aug 04 2011 Richard Hughes  <rhughes at redhat.com> - 0.6.12-4
+- Backport a patch to fix failing the pretransaction check.
+- Resolves #684464
+
 * Fri May 20 2011 Rex Dieter <rdieter at fedoraproject.org> 0.6.12-3
 - Kpackagekit crashes when clicking in any of the groups content (#693027)
 


More information about the scm-commits mailing list