1
0
mirror of https://github.com/systemd/systemd.git synced 2025-01-26 14:04:03 +03:00

mount-util: add one more assertion

This commit is contained in:
Yu Watanabe 2021-06-22 14:41:45 +09:00
parent 9b23679e53
commit 4bee2333cf

View File

@ -564,6 +564,8 @@ static int mount_flags_to_string(long unsigned flags, char **ret) {
};
_cleanup_free_ char *str = NULL;
assert(ret);
for (size_t i = 0; i < ELEMENTSOF(map); i++)
if (flags & map[i].flag) {
if (!strextend_with_separator(&str, "|", map[i].name))