Bug 12496 - Backend ALPM Fails to compile
Summary: Backend ALPM Fails to compile
Alias: None
Product: PackageKit
Classification: Unclassified
Component: General (show other bugs)
Version: unspecified
Hardware: x86 (IA32) Linux (All)
: medium minor
Assignee: Richard Hughes
QA Contact:
Depends on:
Reported: 2007-09-19 17:09 UTC by Harley Laue
Modified: 2007-12-30 01:51 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:

Patch that was in the description. (595 bytes, patch)
2007-09-19 17:12 UTC, Harley Laue
Details | Splinter Review

Description Harley Laue 2007-09-19 17:09:07 UTC
Due to a compiler warning, ALPM fails to compile. It's because when PkPackageId *id is initialized, it's with the declaration. Thus, GCC thinks id is unused.

Below is the git diff since I don't see how to add a patch file:
diff --git a/backends/alpm/pk-backend-alpm.c b/backends/alpm/pk-backend-alpm.c
index 95e6d30..c23a4e5 100644
--- a/backends/alpm/pk-backend-alpm.c
+++ b/backends/alpm/pk-backend-alpm.c
@@ -392,7 +392,8 @@ static void
 backend_get_description (PkBackend *backend, const gchar *package_id)
        g_return_if_fail (backend != NULL);
-       PkPackageId *id = pk_package_id_new_from_string (package_id);
+       PkPackageId *id;
+       id = pk_package_id_new_from_string (package_id);
        //pk_backend_description (backend, package_id, "unknown", PK_GROUP_ENUM_PROGRAMMING, "sdgd");
        pk_backend_finished (backend);
Comment 1 Harley Laue 2007-09-19 17:12:19 UTC
Created attachment 11651 [details] [review]
Patch that was in the description.
Comment 2 Ken VanDine 2007-10-12 04:00:16 UTC
Is this still an issue?
Comment 3 Richard Hughes 2007-12-30 01:51:17 UTC
It should be fine now, please reopen if not the case. Thanks.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.