}
static int mkdir_one(const char *prefix, const char *suffix) {
- char *p;
+ _cleanup_free_ char *p = NULL;
- p = strjoina(prefix, "/", suffix);
+ p = path_join(prefix, suffix);
if (mkdir(p, 0700) < 0) {
if (errno != EEXIST)
return log_error_errno(errno, "Failed to create \"%s\": %m", p);
* partition. Also create the parent directory for entry directories, so that kernel-install
* knows where to put them. */
- r = mkdir_one(dollar_boot_path, "/loader/entries");
+ r = mkdir_one(dollar_boot_path, "loader/entries");
if (r < 0)
return r;