2 * busybox library eXtendet funcion
4 * concatenate path and file name to new allocation buffer,
5 * not addition '/' if path name already have '/'
11 extern char *concat_path_file(const char *path, const char *filename)
16 lc = last_char_is(path, '/');
17 if (filename[0] == '/')
19 outbuf = xmalloc(strlen(path)+strlen(filename)+1+(lc==NULL));
20 sprintf(outbuf, (lc==NULL ? "%s/%s" : "%s%s"), path, filename);