summaryrefslogtreecommitdiff
path: root/cmds-subvolume.c
diff options
context:
space:
mode:
authorZach Brown <zab@redhat.com>2013-08-14 16:16:45 -0700
committerDavid Sterba <dsterba@suse.cz>2013-09-03 19:41:11 +0200
commitc17a056f3841b2ebc024f5af7ed2c58279641d4b (patch)
tree3fdd5851d2a6ffbe66cf5131d39eda0d4f7c5d4a /cmds-subvolume.c
parent0173e6eb83dd120cf6d5063ef4fb5eef5c7eef4c (diff)
btrfs-progs: use NULL instead of 0
These were mostly in option structs but there were a few gross string pointer arguments given as 0. Signed-off-by: Zach Brown <zab@redhat.com> Signed-off-by: David Sterba <dsterba@suse.cz> Signed-off-by: Chris Mason <chris.mason@fusionio.com>
Diffstat (limited to 'cmds-subvolume.c')
-rw-r--r--cmds-subvolume.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/cmds-subvolume.c b/cmds-subvolume.c
index b1e53610..e1fa81aa 100644
--- a/cmds-subvolume.c
+++ b/cmds-subvolume.c
@@ -229,7 +229,7 @@ again:
goto out;
}
- cpath = realpath(path, 0);
+ cpath = realpath(path, NULL);
dname = strdup(cpath);
dname = dirname(dname);
vname = strdup(cpath);
@@ -331,7 +331,7 @@ static int cmd_subvol_list(int argc, char **argv)
int is_only_in_path = 0;
struct option long_options[] = {
{"sort", 1, NULL, 'S'},
- {0, 0, 0, 0}
+ {NULL, 0, NULL, 0}
};
DIR *dirstream = NULL;
@@ -806,7 +806,7 @@ static int cmd_subvol_show(int argc, char **argv)
if (check_argc_exact(argc, 2))
usage(cmd_subvol_show_usage);
- fullpath = realpath(argv[1], 0);
+ fullpath = realpath(argv[1], NULL);
if (!fullpath) {
fprintf(stderr, "ERROR: finding real path for '%s', %s\n",
argv[1], strerror(errno));
@@ -951,7 +951,7 @@ const struct cmd_group subvolume_cmd_group = {
cmd_subvol_set_default_usage, NULL, 0 },
{ "find-new", cmd_find_new, cmd_find_new_usage, NULL, 0 },
{ "show", cmd_subvol_show, cmd_subvol_show_usage, NULL, 0 },
- { 0, 0, 0, 0, 0 }
+ NULL_CMD_STRUCT
}
};