From 56bf74a031bd35054dcc3daba71ddc3068174322 Mon Sep 17 00:00:00 2001 From: Richard Hughes Date: Jun 15 2017 12:44:12 +0000 Subject: Fix a crash when refreshing the metadata cache --- diff --git a/0001-dnf-Fix-an-inverted-condition-that-led-to-frequent-c.patch b/0001-dnf-Fix-an-inverted-condition-that-led-to-frequent-c.patch new file mode 100644 index 0000000..54b6ddf --- /dev/null +++ b/0001-dnf-Fix-an-inverted-condition-that-led-to-frequent-c.patch @@ -0,0 +1,26 @@ +From 3affc66ca3382a9d8b5c2d1f6259c9d283f8561b Mon Sep 17 00:00:00 2001 +From: Kalev Lember +Date: Thu, 15 Jun 2017 14:22:42 +0200 +Subject: [PATCH] dnf: Fix an inverted condition that led to frequent crashes + +https://bugzilla.redhat.com/show_bug.cgi?id=1460825 +--- + backends/dnf/pk-backend-dnf.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/backends/dnf/pk-backend-dnf.c b/backends/dnf/pk-backend-dnf.c +index ead934f1b..a940801f0 100644 +--- a/backends/dnf/pk-backend-dnf.c ++++ b/backends/dnf/pk-backend-dnf.c +@@ -1497,7 +1497,7 @@ pk_backend_refresh_repo (PkBackendJob *job, + } + + /* copy the appstream files somewhere that the GUI will pick them up */ +- if (dnf_utils_refresh_repo_appstream (repo, error)) ++ if (!dnf_utils_refresh_repo_appstream (repo, error)) + return FALSE; + + /* done */ +-- +2.13.0 + diff --git a/PackageKit.spec b/PackageKit.spec index 7d103f3..e0862b7 100644 --- a/PackageKit.spec +++ b/PackageKit.spec @@ -14,7 +14,7 @@ Summary: Package management service Name: PackageKit Version: 1.1.6 -Release: 1%{?dist} +Release: 2%{?dist} License: GPLv2+ and LGPLv2+ URL: http://www.freedesktop.org/software/PackageKit/ Source0: http://www.freedesktop.org/software/PackageKit/releases/%{name}-%{version}.tar.xz @@ -30,6 +30,9 @@ Provides: bundled(libdnf) = 0.7.0 # Fedora-specific: set Vendor.conf up for Fedora. Patch0: PackageKit-0.3.8-Fedora-Vendor.conf.patch +# already upstream +Patch1: 0001-dnf-Fix-an-inverted-condition-that-led-to-frequent-c.patch + BuildRequires: glib2-devel >= %{glib2_version} BuildRequires: xmlto BuildRequires: gtk-doc @@ -189,6 +192,7 @@ tar -xf %{S:1} %endif %patch0 -p1 -b .fedora +%patch1 -p1 -b .crash %build %if 0%{?bundled_libdnf} @@ -339,6 +343,10 @@ systemctl disable packagekit-offline-update.service > /dev/null 2>&1 || : %{_datadir}/vala/vapi/packagekit-glib2.vapi %changelog +* Thu Jun 15 2017 Richard Hughes - 1.1.6-2 +- Fix a crash when refreshing the metadata cache +- Resolves: #1460825 + * Wed Jun 07 2017 Richard Hughes - 1.1.6-1 - New upstream release - Ensure AppStream is deployed when the repo is updated