I've improved "ssh" for now until "sh" is working for the 6809
platforms.
This patch for "ssh" fixed two things:
* cd to user's home directory on login invocation
* a cd without arguments works
if (login_sh) {
home = getenv("HOME");
if (!home) putenv("HOME=/");
- chdir("/");
+ chdir(getenv("HOME"));
}
cprompt = (getuid() == 0) ? "ssh#" : "ssh$";
/* Check for User request to change Current Working Directory */
else if (strcmp(cmd, "cd") == 0) {
- stat = chdir(*arg[0] ? arg[0] : getenv("HOME"));
+ stat = chdir(arg[0] ? arg[0] : getenv("HOME"));
if (stat)
perror("cd");
}