summaryrefslogtreecommitdiffstats
path: root/lib/libalpm/be_local.c
diff options
context:
space:
mode:
authorIvy Foster <ivy.foster@gmail.com>2016-10-12 22:13:32 +0200
committerAllan McRae <allan@archlinux.org>2016-10-22 12:50:55 +0200
commitfa06951d90fee028ece95fc7caab39fc7d35d55f (patch)
tree7bdda990838eb07f2adf5b64b7965c2dcd51cad9 /lib/libalpm/be_local.c
parenta55adb81d0f6fcd7fe98cc444806b3b0d25efc9c (diff)
downloadpacman-fa06951d90fee028ece95fc7caab39fc7d35d55f.tar.gz
pacman-fa06951d90fee028ece95fc7caab39fc7d35d55f.tar.xz
Represent bitfields as ints, not enums
Many bitfield variables are declared to be enums, because they are generated using bitwise operations on enums such. However, their actual values aren't necessary members of their parent enum, so declaring them 'int' is more accurate. Signed-off-by: Ivy Foster <ivy.foster@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
Diffstat (limited to 'lib/libalpm/be_local.c')
-rw-r--r--lib/libalpm/be_local.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/libalpm/be_local.c b/lib/libalpm/be_local.c
index 43c6bc93..123ed6bf 100644
--- a/lib/libalpm/be_local.c
+++ b/lib/libalpm/be_local.c
@@ -47,7 +47,7 @@
/* local database format version */
size_t ALPM_LOCAL_DB_VERSION = 9;
-static int local_db_read(alpm_pkg_t *info, alpm_dbinfrq_t inforeq);
+static int local_db_read(alpm_pkg_t *info, int inforeq);
#define LAZY_LOAD(info, errret) \
do { \
@@ -117,7 +117,7 @@ static alpm_pkgreason_t _cache_get_reason(alpm_pkg_t *pkg)
return pkg->reason;
}
-static alpm_pkgvalidation_t _cache_get_validation(alpm_pkg_t *pkg)
+static int _cache_get_validation(alpm_pkg_t *pkg)
{
LAZY_LOAD(INFRQ_DESC, -1);
return pkg->validation;
@@ -660,7 +660,7 @@ char *_alpm_local_db_pkgpath(alpm_db_t *db, alpm_pkg_t *info,
f = alpm_list_add(f, alpm_dep_from_string(line)); \
} while(1) /* note the while(1) and not (0) */
-static int local_db_read(alpm_pkg_t *info, alpm_dbinfrq_t inforeq)
+static int local_db_read(alpm_pkg_t *info, int inforeq)
{
FILE *fp = NULL;
char line[1024];
@@ -910,7 +910,7 @@ static void write_deps(FILE *fp, const char *header, alpm_list_t *deplist)
fputc('\n', fp);
}
-int _alpm_local_db_write(alpm_db_t *db, alpm_pkg_t *info, alpm_dbinfrq_t inforeq)
+int _alpm_local_db_write(alpm_db_t *db, alpm_pkg_t *info, int inforeq)
{
FILE *fp = NULL;
mode_t oldmask;