diff options
Diffstat (limited to 'src/basic/strv.h')
-rw-r--r-- | src/basic/strv.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/basic/strv.h b/src/basic/strv.h index 1f8da85fcc..71ff3a4edf 100644 --- a/src/basic/strv.h +++ b/src/basic/strv.h @@ -29,7 +29,10 @@ char** strv_free_erase(char **l); DEFINE_TRIVIAL_CLEANUP_FUNC(char**, strv_free_erase); #define _cleanup_strv_free_erase_ _cleanup_(strv_free_erasep) -char** strv_copy(char * const *l); +char** strv_copy_n(char * const *l, size_t n); +static inline char** strv_copy(char * const *l) { + return strv_copy_n(l, SIZE_MAX); +} size_t strv_length(char * const *l) _pure_; int strv_extend_strv(char ***a, char * const *b, bool filter_duplicates); |