aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/rc.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/rc.c b/src/rc.c
index 439bb7b3..0981f633 100644
--- a/src/rc.c
+++ b/src/rc.c
@@ -668,6 +668,9 @@ int main (int argc, char **argv)
atexit (cleanup);
newlevel = argv[0];
+ /* Change dir to / to ensure all scripts don't use stuff in pwd */
+ chdir ("/");
+
/* Setup a signal handler */
signal (SIGINT, handle_signal);
signal (SIGQUIT, handle_signal);