aboutsummaryrefslogtreecommitdiffstats
path: root/src/fm.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/fm.c')
-rw-r--r--src/fm.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/fm.c b/src/fm.c
index cb9cbc1..1af1586 100644
--- a/src/fm.c
+++ b/src/fm.c
@@ -537,7 +537,8 @@ new_dir(fm_info *info)
{
const char *cwd = info->cwd;
char buf[PATH_MAX] = {0};
- if (get_input("Directory name: ", buf) != 0) {
+ size_t len = strlen(buf);
+ if (get_input("Directory name: ", buf, len) != 0) {
return -1;
}