15 ms·
Unix programs start, not in the directory that their binaries are in, but rather in the directory that their parent processes are in. That could be the director
by schoen 6y ago
Unix programs start, not in the directory that their binaries are in, but rather in the directory that their parent processes are in. That could be the directory of the binary if the parent process did a chdir(2) there before spawning the child, but command-line shells never do that unless the user explicitly typed "cd".