about summary refs log tree commit diff
path: root/Src
diff options
context:
space:
mode:
Diffstat (limited to 'Src')
-rw-r--r--Src/Zle/compcore.c4
-rw-r--r--Src/Zle/zle_tricky.c2
2 files changed, 4 insertions, 2 deletions
diff --git a/Src/Zle/compcore.c b/Src/Zle/compcore.c
index 1b16870d1..4c109ed4e 100644
--- a/Src/Zle/compcore.c
+++ b/Src/Zle/compcore.c
@@ -335,7 +335,7 @@ do_completion(Hookdef dummy, Compldat dat)
 	ret = 1;
 	minfo.cur = NULL;
 	if (useline < 0)
-	    selfinsert(zlenoargs);
+	    ret = selfinsert(zlenoargs);
 	goto compend;
     }
     zsfree(lastprebr);
@@ -345,7 +345,7 @@ do_completion(Hookdef dummy, Compldat dat)
     if (comppatmatch && *comppatmatch && comppatmatch != opm)
 	haspattern = 1;
     if (useline < 0)
-	selfinsert(zlenoargs);
+	ret = selfinsert(zlenoargs);
     else if (!useline && uselist) {
 	/* All this and the guy only wants to see the list, sigh. */
 	cs = 0;
diff --git a/Src/Zle/zle_tricky.c b/Src/Zle/zle_tricky.c
index f516fe211..1c706fdd1 100644
--- a/Src/Zle/zle_tricky.c
+++ b/Src/Zle/zle_tricky.c
@@ -159,6 +159,8 @@ usetab(void)
     unsigned char *s = line + cs - 1;
 
     wouldinstab = 0;
+    if (keybuf[0] != '\t' || keybuf[1])
+	return 0;
     for (; s >= line && *s != '\n'; s--)
 	if (*s != '\t' && *s != ' ')
 	    return 0;