aboutsummaryrefslogtreecommitdiffstats
path: root/src/firejail/profile.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/firejail/profile.c')
-rw-r--r--src/firejail/profile.c10
1 files changed, 1 insertions, 9 deletions
diff --git a/src/firejail/profile.c b/src/firejail/profile.c
index 86db82da0..4341434ac 100644
--- a/src/firejail/profile.c
+++ b/src/firejail/profile.c
@@ -433,15 +433,7 @@ void profile_read(const char *fname, const char *skip1, const char *skip2) {
433 } 433 }
434 434
435 // expand ${HOME}/ in front of the new profile file 435 // expand ${HOME}/ in front of the new profile file
436 char *newprofile2 = NULL; 436 char *newprofile2 = expand_home(newprofile, cfg.homedir);
437 if (strncmp(newprofile, "${HOME}", 7) == 0) {
438 if (asprintf(&newprofile2, "%s%s", cfg.homedir, newprofile + 7) == -1)
439 errExit("asprintf");
440 }
441 else if (strncmp(newprofile, "~/", 2) == 0) {
442 if (asprintf(&newprofile2, "%s%s", cfg.homedir, newprofile + 1) == -1)
443 errExit("asprintf");
444 }
445 437
446 // recursivity 438 // recursivity
447 profile_read((newprofile2)? newprofile2:newprofile, newskip1, newskip2); 439 profile_read((newprofile2)? newprofile2:newprofile, newskip1, newskip2);