diff options
author | Nicholas Marriott <nicm@openbsd.org> | 2012-02-06 17:29:29 +0000 |
---|---|---|
committer | Nicholas Marriott <nicm@openbsd.org> | 2012-02-06 17:29:29 +0000 |
commit | 67949de0a173901fc741674c31bb971172442ec9 (patch) | |
tree | 3df1b79c6cfd29f515458a99e1767ca3c2048c91 /cmd.c | |
parent | 3f49137f9027f0c2cf8b0318548a69505c4708ab (diff) |
Don't die if fail to get root directory, from Ben Boeckel.
Diffstat (limited to 'cmd.c')
-rw-r--r-- | cmd.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -1309,7 +1309,8 @@ cmd_get_default_path(struct cmd_ctx *ctx, const char *cwd) else return (s->cwd); skip = 0; - goto complete_path; + if (root != NULL) + goto complete_path; } return (s->cwd); |