Yes, Karmic shows the exact same behaviour. The only difference is that /bin/sh points to /bin/dash nowdays, however creating a link to /bin/bash named sh shows the same behaviour as the original bug report:
tor...@skruttibangbang:~$ /bin/bash tor...@skruttibangbang:~$ mkdir /scratch/kalle tor...@skruttibangbang:~$ cd /scratch/kalle/ tor...@skruttibangbang:/scratch/kalle$ rmdir /scratch/kalle tor...@skruttibangbang:/scratch/kalle$ cd . cd: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory tor...@skruttibangbang:/scratch/kalle/.$ echo $? 0 tor...@skruttibangbang:/scratch/kalle/.$ pwd /scratch/kalle/. tor...@skruttibangbang:/scratch/kalle/.$ exit exit tor...@skruttibangbang:~$ /bin/sh $ mkdir /scratch/kalle $ cd /scratch/kalle/ $ rmdir /scratch/kalle $ cd . cd: 4: can't cd to . $ echo $? 2 $ pwd /scratch/kalle $ ls -l /bin/sh lrwxrwxrwx 1 root root 4 2009-05-20 01:24 /bin/sh -> dash $ exit tor...@skruttibangbang:~$ /scratch/sh sh-4.0$ mkdir /scratch/kalle sh-4.0$ cd /scratch/kalle/ sh-4.0$ rmdir /scratch/kalle sh-4.0$ cd . sh: cd: .: No such file or directory sh-4.0$ echo $? 1 sh-4.0$ pwd pwd: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory sh-4.0$ ls -l /scratch/sh lrwxrwxrwx 1 torkel torkel 9 2009-08-28 08:04 /scratch/sh -> /bin/bash sh-4.0$ exit exit tor...@skruttibangbang:~$ bash --version GNU bash, version 4.0.28(1)-release (x86_64-pc-linux-gnu) Copyright (C) 2009 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software; you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. -- bash returns wrong error code when changing to nonexisting directory https://bugs.launchpad.net/bugs/85552 You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs