about summary refs log tree commit diff
path: root/Src
diff options
context:
space:
mode:
authorTanaka Akira <akr@users.sourceforge.net>1999-08-24 08:38:09 +0000
committerTanaka Akira <akr@users.sourceforge.net>1999-08-24 08:38:09 +0000
commit9e879a8a68c52a4a0319fcc0eb8a6c2ab565a4e4 (patch)
tree9076b5e25ee5b1ce625e29bd5460ca4beb40d9fa /Src
parent02ce2d213b4cd91991e6457cf25b0a4450109b05 (diff)
downloadzsh-9e879a8a68c52a4a0319fcc0eb8a6c2ab565a4e4.tar.gz
zsh-9e879a8a68c52a4a0319fcc0eb8a6c2ab565a4e4.tar.xz
zsh-9e879a8a68c52a4a0319fcc0eb8a6c2ab565a4e4.zip
zsh-users/2505
Diffstat (limited to 'Src')
-rw-r--r--Src/Zle/zle_tricky.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/Src/Zle/zle_tricky.c b/Src/Zle/zle_tricky.c
index 975c5d124..2309fe27f 100644
--- a/Src/Zle/zle_tricky.c
+++ b/Src/Zle/zle_tricky.c
@@ -800,10 +800,12 @@ check_param(char *s, int set, int test)
 		/* Get the prefix (anything up to the character before the name). */
 		isuf = dupstring(e);
 		untokenize(isuf);
-		*e = '\0';
+		sav = *b;
+		*b = *e = '\0';
 		ripre = dyncat((ripre ? ripre : ""), s);
 		ipre = dyncat((ipre ? ipre : ""), s);
-		ripre[b - s] = '\0';
+		*b = sav;
+
 		untokenize(ipre);
 	    }
 	    else