strv: add helper to extend strv from both sides

Also, use the more correct type of 'const char* const*' for the input strv.
This requires adding the cast in a few places, but also allows to remove some
casts in others.
This commit is contained in:
Zbigniew Jędrzejewski-Szmek
2024-03-07 18:49:44 +01:00
parent 4bf32eac52
commit 9bc7493098
7 changed files with 29 additions and 10 deletions
+1 -1
View File
@@ -369,7 +369,7 @@ int conf_files_list_dropins(
assert(dirs);
suffix = strjoina("/", dropin_dirname);
r = strv_extend_strv_concat(&dropin_dirs, (char**) dirs, suffix);
r = strv_extend_strv_concat(&dropin_dirs, dirs, suffix);
if (r < 0)
return r;