2 * (c) 2013 Carsten Weinhold <weinhold@os.inf.tu-dresden.de>
3 * economic rights: Technische Universität Dresden (Germany)
4 * This file is part of TUD:OS and distributed under the terms of the
5 * GNU Lesser General Public License 2.1.
6 * Please see the COPYING-LGPL-2.1 file for details.
13 static void set_initial_cwd(void) __attribute__((constructor));
14 static void set_initial_cwd()
16 char *initial_dir = getenv("INIT_CWD");
19 int err = chdir(initial_dir);
21 printf("libinitcwd: could not chdir to '%s'.\n", initial_dir);