Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/lib/libalpm/trans.h
diff options
context:
space:
mode:
authorIvy Foster <ivy.foster@gmail.com>2016-10-12 15:13:32 -0500
committerAllan McRae <allan@archlinux.org>2016-10-22 20:50:55 +1000
commitfa06951d90fee028ece95fc7caab39fc7d35d55f (patch)
tree7bdda990838eb07f2adf5b64b7965c2dcd51cad9 /lib/libalpm/trans.h
parenta55adb81d0f6fcd7fe98cc444806b3b0d25efc9c (diff)
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/trans.h')
-rw-r--r--lib/libalpm/trans.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/libalpm/trans.h b/lib/libalpm/trans.h
index 73111be4..ac13b891 100644
--- a/lib/libalpm/trans.h
+++ b/lib/libalpm/trans.h
@@ -37,7 +37,8 @@ typedef enum _alpm_transstate_t {
/* Transaction */
struct __alpm_trans_t {
- alpm_transflag_t flags;
+ /* bitfield of alpm_transflag_t flags */
+ int flags;
alpm_transstate_t state;
alpm_list_t *unresolvable; /* list of (alpm_pkg_t *) */
alpm_list_t *add; /* list of (alpm_pkg_t *) */
@@ -46,7 +47,8 @@ struct __alpm_trans_t {
};
void _alpm_trans_free(alpm_trans_t *trans);
-int _alpm_trans_init(alpm_trans_t *trans, alpm_transflag_t flags);
+/* flags is a bitfield of alpm_transflag_t flags */
+int _alpm_trans_init(alpm_trans_t *trans, int flags);
int _alpm_runscriptlet(alpm_handle_t *handle, const char *filepath,
const char *script, const char *ver, const char *oldver, int is_archive);