summaryrefslogtreecommitdiff
path: root/lib/libalpm/package.c
diff options
context:
space:
mode:
authorXavier Chantry <shiningxc@gmail.com>2009-12-05 01:50:09 +0100
committerDan McGee <dan@archlinux.org>2010-03-14 19:25:48 -0500
commit1aa1d00248ac89fb02e762b96c58559a04679b2e (patch)
tree0326bf37268fa6167f4b17e38b58bda598a82da4 /lib/libalpm/package.c
parentbe2f43191d0d0cdf02d72ac72a013697b0f7e879 (diff)
downloadpacman-1aa1d00248ac89fb02e762b96c58559a04679b2e.tar.xz
fix a few warnings reported by clang
- remove unused variables - some more sanity checks - safer printf Signed-off-by: Xavier Chantry <shiningxc@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'lib/libalpm/package.c')
-rw-r--r--lib/libalpm/package.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/libalpm/package.c b/lib/libalpm/package.c
index 4ff04dab..ef0f63a2 100644
--- a/lib/libalpm/package.c
+++ b/lib/libalpm/package.c
@@ -459,7 +459,6 @@ void SYMEXPORT *alpm_pkg_changelog_open(pmpkg_t *pkg)
struct archive *archive = NULL;
struct archive_entry *entry;
const char *pkgfile = pkg->origin_data.file;
- int ret = ARCHIVE_OK;
if((archive = archive_read_new()) == NULL) {
RET_ERR(PM_ERR_LIBARCHIVE, NULL);
@@ -473,7 +472,7 @@ void SYMEXPORT *alpm_pkg_changelog_open(pmpkg_t *pkg)
RET_ERR(PM_ERR_PKG_OPEN, NULL);
}
- while((ret = archive_read_next_header(archive, &entry)) == ARCHIVE_OK) {
+ while(archive_read_next_header(archive, &entry) == ARCHIVE_OK) {
const char *entry_name = archive_entry_pathname(entry);
if(strcmp(entry_name, ".CHANGELOG") == 0) {