From 92881643eeef732af9a99427bb5382e18d1e923e Mon Sep 17 00:00:00 2001 From: Tanaka Akira Date: Wed, 15 Sep 1999 12:05:46 +0000 Subject: zsh-workers/7834 --- Src/pattern.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/Src/pattern.c b/Src/pattern.c index e5c0a0cb3..63551967f 100644 --- a/Src/pattern.c +++ b/Src/pattern.c @@ -338,11 +338,12 @@ patcompile(char *exp, int inflags, char **endexp) if (!(patflags & PAT_ANY)) { /* Look for a really pure string, with no tokens at all. */ - for (strp = exp; *strp && - (!(patflags & PAT_FILE) || *strp != '/') && !itok(*strp); - strp++) - ; - if (*strp && *strp != '/') { + if (!patglobflags) + for (strp = exp; *strp && + (!(patflags & PAT_FILE) || *strp != '/') && !itok(*strp); + strp++) + ; + if (!strp || (*strp && *strp != '/')) { /* No, do normal compilation. */ strp = NULL; if (patcompswitch(0, &flags) == 0) -- cgit 1.4.1