diff options
Diffstat (limited to 'regex.c')
-rw-r--r-- | regex.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -1,4 +1,4 @@ -/* $Id: regex.c,v 1.9 2002/01/10 16:11:32 ukai Exp $ */ +/* $Id: regex.c,v 1.10 2002/01/11 02:24:13 a-ito Exp $ */ /* * regex: Regular expression pattern match library * @@ -265,7 +265,7 @@ RegexMatch(Regex *re, char *str, int len, int firstp) len = strlen(str); re->position = NULL; ep = str + len; - for (p = str; p < ep; p++) { + for (p = str; p <= ep; p++) { lpos = NULL; re->lposition = NULL; for (r = re; r != NULL; r = r->alt_regex) { @@ -554,7 +554,7 @@ regmatch_iter(struct MatchingContext1 *c, c->re++; c->firstp = 0; } - if (c->str >= c->end_p) { + if (c->str > c->end_p) { return 0; } } |