journal: move definition of LocationType to journal-file.h

In preparation for individual JournalFiles maintaining a location
of their own.
This commit is contained in:
Michal Schmidt 2014-12-16 20:51:58 +01:00
parent 8a2bd0a365
commit 99cc7653a8
2 changed files with 14 additions and 14 deletions

View file

@ -48,6 +48,20 @@ typedef enum direction {
DIRECTION_DOWN
} direction_t;
typedef enum LocationType {
/* The first and last entries, resp. */
LOCATION_HEAD,
LOCATION_TAIL,
/* We already read the entry we currently point to, and the
* next one to read should probably not be this one again. */
LOCATION_DISCRETE,
/* We should seek to the precise location specified, and
* return it, as we haven't read it yet. */
LOCATION_SEEK
} LocationType;
typedef struct JournalFile {
int fd;

View file

@ -57,20 +57,6 @@ struct Match {
LIST_HEAD(Match, matches);
};
typedef enum LocationType {
/* The first and last entries, resp. */
LOCATION_HEAD,
LOCATION_TAIL,
/* We already read the entry we currently point to, and the
* next one to read should probably not be this one again. */
LOCATION_DISCRETE,
/* We should seek to the precise location specified, and
* return it, as we haven't read it yet. */
LOCATION_SEEK
} LocationType;
struct Location {
LocationType type;