summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--mbbsd/name.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/mbbsd/name.c b/mbbsd/name.c
index db96eb08..9a53e086 100644
--- a/mbbsd/name.c
+++ b/mbbsd/name.c
@@ -566,6 +566,8 @@ generalnamecomplete(char *prompt, char *data, int len, size_t nmemb,
if (ptr != 0) {
gnc_findbound(data, &start, &end, nmemb, compar);
ret = gnc_completeone(data, start, end, permission, getname);
+ if (ret < 0)
+ data[0] = 0;
} else
ptr = -1;
break;