From: Christoph M. Becker Date: Wed, 13 May 2015 21:47:54 +0000 (+0200) Subject: fix #69628: complex GLOB_BRACE fails on Windows X-Git-Tag: PRE_PHP7_NSAPI_REMOVAL~42^2~12^2~2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e42aae1e9bf5e15d8114c8ae4b5e99cc6e555d9b;p=php fix #69628: complex GLOB_BRACE fails on Windows --- diff --git a/win32/glob.c b/win32/glob.c index 43884509ce..1541fcf966 100644 --- a/win32/glob.c +++ b/win32/glob.c @@ -293,17 +293,19 @@ globexp2(ptr, pattern, pglob, rv) } for (i = 0, pl = pm = ptr; pm <= pe; pm++) { + const Char *pb; + switch (*pm) { case LBRACKET: /* Ignore everything between [] */ - for (pl = pm++; *pm != RBRACKET && *pm != EOS; pm++) + for (pb = pm++; *pm != RBRACKET && *pm != EOS; pm++) ; if (*pm == EOS) { /* * We could not find a matching RBRACKET. * Ignore and just look for RBRACE */ - pm = pl; + pm = pb; } break;