Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
[PATCH] don't treat alone grouping pattern as glob qualifier
- X-seq: zsh-workers 31995
- From: Han Pingtian <hanpt@xxxxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: [PATCH] don't treat alone grouping pattern as glob qualifier
- Date: Sun, 17 Nov 2013 13:24:23 +0800
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
Hello,
I think this is a minor bug:
% ls
a sym1 sym2 sym3 sym4 testfile
% print (s*)
zsh: no match
%
Looks like the alone grouping pattern (s*) is treated as qualifier.
And I have figured out a patch which looks like fixes the issue. Please
have a look.
Thanks.
---
Src/glob.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/Src/glob.c b/Src/glob.c
index e0d0cf6..385b9e6 100644
--- a/Src/glob.c
+++ b/Src/glob.c
@@ -1171,7 +1171,7 @@ zglob(LinkList list, LinkNode np, int nountok)
break;
}
}
- if (*s != Inpar)
+ if (*s != Inpar || s == str)
break;
if (isset(EXTENDEDGLOB) && !zpc_disables[ZPC_HASH] && s[1] == Pound) {
if (s[2] == 'q') {
--
1.7.7.6
Messages sorted by:
Reverse Date,
Date,
Thread,
Author