added chdir to init.hh