summaryrefslogtreecommitdiffstats
path: root/lib/libalpm/package.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libalpm/package.c')
-rw-r--r--lib/libalpm/package.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/lib/libalpm/package.c b/lib/libalpm/package.c
index 531d91a2..a47ae2fc 100644
--- a/lib/libalpm/package.c
+++ b/lib/libalpm/package.c
@@ -100,10 +100,8 @@ pmpkg_t *_alpm_pkg_dup(pmpkg_t *pkg)
return(newpkg);
}
-void _alpm_pkg_free(void *data)
+void _alpm_pkg_free(pmpkg_t *pkg)
{
- pmpkg_t *pkg = data;
-
ALPM_LOG_FUNC;
if(pkg == NULL) {
@@ -125,8 +123,6 @@ void _alpm_pkg_free(void *data)
FREE(pkg->data);
}
FREE(pkg);
-
- return;
}
/* Is pkgB an upgrade for pkgA ? */
@@ -455,7 +451,7 @@ pkg_invalid:
close(fd);
}
error:
- FREEPKG(info);
+ _alpm_pkg_free(info);
archive_read_finish(archive);
return(NULL);