mirror of
https://github.com/koverstreet/bcachefs-tools.git
synced 2025-02-02 00:00:03 +03:00
Fix null ptr deref in bbpos_parse()
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
This commit is contained in:
parent
54b6beabf0
commit
63747ac653
@ -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;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user