dissect-image: simplification

This commit is contained in:
Lennart Poettering
2025-09-20 08:40:25 +02:00
committed by Yu Watanabe
parent 5c7be92494
commit 341bccdf1e

View File

@@ -81,11 +81,9 @@ static int allowed_fstypes(char ***ret_strv) {
assert(ret_strv);
e = secure_getenv("SYSTEMD_DISSECT_FILE_SYSTEMS");
if (e) {
if (e)
l = strv_split(e, ":");
if (!l)
return -ENOMEM;
} else {
else
l = strv_new("btrfs",
"erofs",
"ext4",
@@ -93,12 +91,10 @@ static int allowed_fstypes(char ***ret_strv) {
"squashfs",
"vfat",
"xfs");
if (!l)
return -ENOMEM;
}
if (!l)
return -ENOMEM;
*ret_strv = TAKE_PTR(l);
return 0;
}