Fixes chdir retval

Was returning -errno on errors, instead of -1.  Also, this cleans up the
discrepancy betweren how do_chdir() and do_fchdir() handle errno and return
values.