index : pacman | |
Archlinux32 fork of pacman | gitolite user |
summaryrefslogtreecommitdiff |
author | Allan McRae <allan@archlinux.org> | 2015-02-25 01:05:20 +1000 |
---|---|---|
committer | Allan McRae <allan@archlinux.org> | 2015-03-03 16:54:17 +1000 |
commit | 578ceb29faa2673b7b0e4f4cc311ba77d6acb4b4 (patch) | |
tree | 2b1aa758cac73c1473a670caa15c1ee75491fa32 | |
parent | 9f1c5f0251c202ad504f03464da23a5050914157 (diff) |
-rw-r--r-- | src/pacman/sync.c | 5 |
diff --git a/src/pacman/sync.c b/src/pacman/sync.c index 91eca7e4..0c3151e1 100644 --- a/src/pacman/sync.c +++ b/src/pacman/sync.c @@ -94,7 +94,10 @@ static int sync_cleandb(const char *dbpath, int keep_used) snprintf(path, PATH_MAX, "%s%s", dbpath, dname); /* remove all non-skipped directories and non-database files */ - stat(path, &buf); + if(stat(path, &buf) == -1) { + pm_printf(ALPM_LOG_ERROR, _("could not remove %s: %s\n"), + path, strerror(errno)); + } if(S_ISDIR(buf.st_mode)) { if(rmrf(path)) { pm_printf(ALPM_LOG_ERROR, _("could not remove %s: %s\n"), |