RTEMS shell and chdir

Peter Dufault dufault at hda.com
Tue Jul 15 21:02:02 UTC 2014

A friend started trying RTEMS and noted that the RTEMS shell doesn't work as he expected - each shell maintains its own current working directory.   Furthermore, a "chdir()" in a routine that then creates a shell doesn't get the working directory from the "chdir()".

Searching about "current working directory" and "pthreads" or POSIX threads results in Linux and other man pages that state that the current working directory is shared across all threads in a process.  The RTEMS shell seems to be calling "getcwd()" to get back the directory for the shell.  Is there a single current working directory in RTEMS?  Should "chdir" in one shell result in all shells having a different current working directory?  How does it work now?

Peter Dufault
HD Associates, Inc.      Software and System Engineering

More information about the users mailing list