diff --git a/lib/package_unpack.c b/lib/package_unpack.c index 257b1795..1dacbff3 100644 --- a/lib/package_unpack.c +++ b/lib/package_unpack.c @@ -609,7 +609,7 @@ xbps_unpack_binary_pkg(prop_dictionary_t pkg_repod) "%s: [unpack] failed to open binary package `%s': %s", pkgver, fname, strerror(rv)); free(bpkg); - archive_read_finish(ar); + archive_read_free(ar); return rv; } free(bpkg); diff --git a/lib/plist_fetch.c b/lib/plist_fetch.c index d6e94260..a9b6605a 100644 --- a/lib/plist_fetch.c +++ b/lib/plist_fetch.c @@ -198,7 +198,8 @@ xbps_dictionary_metadata_plist_by_url(const char *url, const char *plistf) break; } - archive_read_finish(a); + archive_read_close(a); + archive_read_free(a); return plistd; }