summaryrefslogtreecommitdiff
path: root/tools-util.c
diff options
context:
space:
mode:
Diffstat (limited to 'tools-util.c')
-rw-r--r--tools-util.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/tools-util.c b/tools-util.c
index 624656a1..81ce63ae 100644
--- a/tools-util.c
+++ b/tools-util.c
@@ -671,6 +671,10 @@ struct bbpos bbpos_parse(char *buf)
die("invalid bbpos %s", buf);
ret.btree = read_string_list_or_die(field, bch2_btree_ids, "btree id");
+
+ if (!s)
+ die("invalid bbpos %s", buf);
+
ret.pos = bpos_parse(s);
return ret;
}