summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--btrfs-list.c5
-rw-r--r--btrfs-list.h11
2 files changed, 10 insertions, 6 deletions
diff --git a/btrfs-list.c b/btrfs-list.c
index 5d9a79ab..02b30b52 100644
--- a/btrfs-list.c
+++ b/btrfs-list.c
@@ -1457,7 +1457,7 @@ static void print_all_volume_info_tab_head(void)
}
static void print_all_volume_info(struct root_lookup *sorted_tree,
- int layout, const char *raw_prefix)
+ enum btrfs_list_layout layout, const char *raw_prefix)
{
struct rb_node *n;
struct root_info *entry;
@@ -1504,7 +1504,8 @@ static int btrfs_list_subvols(int fd, struct root_lookup *root_lookup)
int btrfs_list_subvols_print(int fd, struct btrfs_list_filter_set *filter_set,
struct btrfs_list_comparer_set *comp_set,
- int layout, int full_path, const char *raw_prefix)
+ enum btrfs_list_layout layout, int full_path,
+ const char *raw_prefix)
{
struct root_lookup root_lookup;
struct root_lookup root_sort;
diff --git a/btrfs-list.h b/btrfs-list.h
index 68927036..a39a01a0 100644
--- a/btrfs-list.h
+++ b/btrfs-list.h
@@ -31,9 +31,11 @@
#include <time.h>
-#define BTRFS_LIST_LAYOUT_DEFAULT 0
-#define BTRFS_LIST_LAYOUT_TABLE 1
-#define BTRFS_LIST_LAYOUT_RAW 2
+enum btrfs_list_layout {
+ BTRFS_LIST_LAYOUT_DEFAULT = 0,
+ BTRFS_LIST_LAYOUT_TABLE,
+ BTRFS_LIST_LAYOUT_RAW
+};
/*
* one of these for each root we find.
@@ -166,7 +168,8 @@ struct btrfs_list_comparer_set *btrfs_list_alloc_comparer_set(void);
int btrfs_list_subvols_print(int fd, struct btrfs_list_filter_set *filter_set,
struct btrfs_list_comparer_set *comp_set,
- int is_tab_result, int full_path, const char *raw_prefix);
+ enum btrfs_list_layout layot, int full_path,
+ const char *raw_prefix);
int btrfs_list_find_updated_files(int fd, u64 root_id, u64 oldest_gen);
int btrfs_list_get_default_subvolume(int fd, u64 *default_id);
char *btrfs_list_path_for_root(int fd, u64 root);