summaryrefslogtreecommitdiffstats
path: root/lib/libalpm/diskspace.c
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2011-06-27 17:10:08 +0200
committerDan McGee <dan@archlinux.org>2011-06-27 17:10:08 +0200
commitf01c6f814a278a3d024d34fed0c219c8cb1e1e33 (patch)
tree759833d3d7c46bca4f962c5fd442ab3f37d85b14 /lib/libalpm/diskspace.c
parent77a09c92c66bd06440be0ccb75daf07c620acbee (diff)
downloadpacman-f01c6f814a278a3d024d34fed0c219c8cb1e1e33.tar.gz
pacman-f01c6f814a278a3d024d34fed0c219c8cb1e1e33.tar.xz
Fix several -Wshadow warnings
Only one of these looked like a real red flag, in find_requiredby(), but it doesn't hurt to fix several of them up anyway. Unfortunately, we can't turn this on universally due to things like the sync(), remove(), etc. builtins which we often use as variable names. Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'lib/libalpm/diskspace.c')
-rw-r--r--lib/libalpm/diskspace.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/libalpm/diskspace.c b/lib/libalpm/diskspace.c
index 079e683e..51aa47f2 100644
--- a/lib/libalpm/diskspace.c
+++ b/lib/libalpm/diskspace.c
@@ -262,7 +262,7 @@ int _alpm_check_diskspace(pmhandle_t *handle)
alpm_list_t *mount_points, *i;
alpm_mountpoint_t *root_mp;
size_t replaces = 0, current = 0, numtargs;
- int abort = 0;
+ int error = 0;
alpm_list_t *targ;
pmtrans_t *trans = handle->trans;
@@ -323,7 +323,7 @@ int _alpm_check_diskspace(pmhandle_t *handle)
if(data->used && data->read_only) {
_alpm_log(handle, PM_LOG_ERROR, _("Partition %s is mounted read only\n"),
data->mount_dir);
- abort = 1;
+ error = 1;
} else if(data->used & USED_INSTALL) {
/* cushion is roughly min(5% capacity, 20MiB) */
long fivepc = ((long)data->fsp.f_blocks / 20) + 1;
@@ -338,7 +338,7 @@ int _alpm_check_diskspace(pmhandle_t *handle)
_alpm_log(handle, PM_LOG_ERROR, _("Partition %s too full: %ld blocks needed, %ld blocks free\n"),
data->mount_dir, data->max_blocks_needed + cushion,
(unsigned long)data->fsp.f_bfree);
- abort = 1;
+ error = 1;
}
}
}
@@ -349,7 +349,7 @@ int _alpm_check_diskspace(pmhandle_t *handle)
}
FREELIST(mount_points);
- if(abort) {
+ if(error) {
RET_ERR(handle, PM_ERR_DISK_SPACE, -1);
}