about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog3
-rw-r--r--Src/Zle/computil.c4
2 files changed, 5 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index 52959a04a..b8b6f40fc 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2008-10-14  Clint Adams  <clint@zsh.org>
 
+	* 25897: Src/Zle/computil.c: remove small bit of dead code in
+	cfp_opt_pats.
+
 	* 25896: Src/builtin.c: remove small bit of dead code in
 	execbuiltin.
 
diff --git a/Src/Zle/computil.c b/Src/Zle/computil.c
index 6c82d010e..0801e0c2d 100644
--- a/Src/Zle/computil.c
+++ b/Src/Zle/computil.c
@@ -4351,12 +4351,12 @@ cfp_opt_pats(char **pats, char *matcher)
 		    for (s = add; *s && !idigit(*s); s++);
 		    *s = '\0';
 		} else if (*q == '[') {
-		    int not, first = 1;
+		    int not;
 		    char *x = ++q;
 
 		    if ((not = (*x == '!' || *x == '^')))
 			x++;
-		    for (; *x && (first || *x != ']'); x++) {
+		    for (; *x; x++) {
 			if (x[1] == '-' && x[2]) {
 			    char c1 = *x, c2 = x[2];