plorkyeran parent
chdir is thread-safe, but interacting with the current directory in any context other than parsing command-line arguments is still nearly always a mistake. Everything past a program's entry point should be working exclusively in absolute paths.
Yeah if you chdir() in a multithreaded program, all cwd-relative file accesses in other threads are fucked.
As well as absolute paths, it’s ok to work with descriptor-relative paths using openat() and friends.