path-lookup: LookupPathsFlags are a flags type, hence define it like one

We shouldn't rely on C's incremental assignment of values of enums for
bit fields. That'll work only between the first two flags, but for
everything following will break horrible. Hence, let's avoid any
ambiguity here, and let's clearly define the flags as shifts of 1.
This commit is contained in:
Lennart Poettering
2017-11-23 17:37:49 +01:00
parent e9f4aabd80
commit fbc5883523

View File

@@ -28,8 +28,8 @@ typedef struct LookupPaths LookupPaths;
#include "macro.h"
typedef enum LookupPathsFlags {
LOOKUP_PATHS_EXCLUDE_GENERATED = 1,
LOOKUP_PATHS_TEMPORARY_GENERATED,
LOOKUP_PATHS_EXCLUDE_GENERATED = 1 << 0,
LOOKUP_PATHS_TEMPORARY_GENERATED = 1 << 1,
} LookupPathsFlags;
struct LookupPaths {