]> git.proxmox.com Git - mirror_lxc.git/blobdiff - src/lxc/string_utils.c
cgroups: flatten hierarchy
[mirror_lxc.git] / src / lxc / string_utils.c
index 4e8fc21811fde1879f4ac28acce14fbaacfed456..dcb1160e4cc58247a77a0332352866c7761d2681 100644 (file)
@@ -730,7 +730,7 @@ int lxc_safe_long_long(const char *numstr, long long int *converted)
        return 0;
 }
 
-char *must_concat(const char *first, ...)
+char *must_concat(size_t *len, const char *first, ...)
 {
        va_list args;
        char *cur, *dest;
@@ -751,6 +751,8 @@ char *must_concat(const char *first, ...)
        va_end(args);
 
        dest[cur_len] = '\0';
+       if (len)
+               *len = cur_len;
        return dest;
 }