Commit 9576eb62 authored by Benno Schulenberg's avatar Benno Schulenberg
Browse files

browser: show a message when getcwd() fails, instead of just beeping

No related merge requests found
Showing with 6 additions and 1 deletion
+6 -1
......@@ -385,7 +385,12 @@ char *do_browse_from(const char *inpath)
path = charalloc(PATH_MAX + 1);
path = getcwd(path, PATH_MAX + 1);
if (path != NULL)
if (path == NULL) {
statusline(MILD, "The working directory has disappeared");
beep();
napms(1200);
return NULL;
} else
align(&path);
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment