summaryrefslogtreecommitdiff
path: root/Src/glob.c
diff options
context:
space:
mode:
Diffstat (limited to 'Src/glob.c')
-rw-r--r--Src/glob.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/Src/glob.c b/Src/glob.c
index ca5846704..f67a376b9 100644
--- a/Src/glob.c
+++ b/Src/glob.c
@@ -3059,7 +3059,7 @@ igetmatch(char **sp, Patprog p, int fl, int n, char *replstr,
case (SUB_END|SUB_SUBSTR):
case (SUB_END|SUB_LONG|SUB_SUBSTR):
/* Longest/shortest at end, matching substrings. */
- if (!(fl & SUB_LONG)) {
+ {
set_pat_start(p, l);
if (pattrylen(p, send, 0, 0, &patstralloc, umltot) &&
!--n) {
@@ -3397,7 +3397,7 @@ igetmatch(char **sp, Patprog p, int fl, int n, char *replstr,
case (SUB_END|SUB_SUBSTR):
case (SUB_END|SUB_LONG|SUB_SUBSTR):
/* Longest/shortest at end, matching substrings. */
- if (!(fl & SUB_LONG)) {
+ {
set_pat_start(p, l);
if (pattrylen(p, send, 0, 0, &patstralloc, uml) && !--n) {
*sp = get_match_ret(&imd, uml, uml);