diff options
author | sin <sin@2f30.org> | 2014-02-12 09:33:06 +0000 |
---|---|---|
committer | sin <sin@2f30.org> | 2014-02-12 09:33:06 +0000 |
commit | c09709f04fb60c89e0b6d401eac8785d4523b52d (patch) | |
tree | 35ed84a40b3aed3b9405c30d34862e2f6f60e686 | |
parent | 31dbd779dcbd5b7c2cd96a008f1f93c035e0a4f7 (diff) |
Sanitize working dir - default to "/"
-rw-r--r-- | sinit.c | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -36,6 +36,8 @@ main(void) return EXIT_FAILURE; setsid(); + chdir("/"); + sigemptyset(&set); for (i = 0; i < LEN(sigmap); i++) sigaddset(&set, sigmap[i].sig); |