summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAllan McRae <allan@archlinux.org>2019-11-26 02:37:32 +0100
committerAllan McRae <allan@archlinux.org>2019-11-26 02:37:32 +0100
commit1e23b4585146b5c2bced10293c0f3486e53d51ed (patch)
tree7511ff0dfe9f4cd6b6b60cbb05503ac9be4fdd3d /src
parent3073752bcd9718b243661dd727e8f8bc18035938 (diff)
downloadpacman-1e23b4585146b5c2bced10293c0f3486e53d51ed.tar.gz
pacman-1e23b4585146b5c2bced10293c0f3486e53d51ed.tar.xz
Fix documentation of alpm_mtree_next and remove libarchive exposure
The documentation of the return types of alpm_mtree_next was incorrect. This extended into the relevant function in be_local.c. Also, return explicit integer values, rather than the ARCHIVE_xxx values, to avoid unnecessarily exposing frontends to libarchive internals (even though it makes no functional difference). Original-work-by: morganamilo <morganamilo@archlinux.org> Signed-off-by: Allan McRae <allan@archlinux.org>
Diffstat (limited to 'src')
-rw-r--r--src/pacman/check.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/pacman/check.c b/src/pacman/check.c
index ab35891a..85b25f39 100644
--- a/src/pacman/check.c
+++ b/src/pacman/check.c
@@ -277,7 +277,7 @@ int check_pkg_full(alpm_pkg_t *pkg)
return 0;
}
- while(alpm_pkg_mtree_next(pkg, mtree, &entry) == ARCHIVE_OK) {
+ while(alpm_pkg_mtree_next(pkg, mtree, &entry) == 0) {
struct stat st;
const char *path = archive_entry_pathname(entry);
char filepath[PATH_MAX];