From: Tangles Date: Sat, 22 Feb 2020 01:03:00 +0000 (+1100) Subject: Try to use the dglroot dir as home if we are doing the chroot X-Git-Tag: v1.6.1-roc-dev~19 X-Git-Url: https://skyeroc.xyz/gitweb/?a=commitdiff_plain;h=7a1120e9e754774e538ece3e9fb4faed8243c113;p=dgamelaunch Try to use the dglroot dir as home if we are doing the chroot --- diff --git a/dgamelaunch.c b/dgamelaunch.c index d8d2b18..80178f6 100644 --- a/dgamelaunch.c +++ b/dgamelaunch.c @@ -3123,7 +3123,11 @@ main (int argc, char** argv) graceful_exit (2); } - if (chdir ("/")) + if (chdir (globalconfig.dglroot)) + { + perror("warning: cannot chdir to dglroot directory, using / instead"); + } + else if (chdir ("/")) { perror ("cannot chdir to root directory"); graceful_exit (3);