| 292 |
|
|
| 293 |
const uschar *Xeptr; |
const uschar *Xeptr; |
| 294 |
const uschar *Xecode; |
const uschar *Xecode; |
| 295 |
const uschar *Xmstart; |
const uschar *Xmstart; |
| 296 |
int Xoffset_top; |
int Xoffset_top; |
| 297 |
long int Xims; |
long int Xims; |
| 298 |
eptrblock *Xeptrb; |
eptrblock *Xeptrb; |
| 374 |
eptr pointer to current character in subject |
eptr pointer to current character in subject |
| 375 |
ecode pointer to current position in compiled code |
ecode pointer to current position in compiled code |
| 376 |
mstart pointer to the current match start position (can be modified |
mstart pointer to the current match start position (can be modified |
| 377 |
by encountering \K) |
by encountering \K) |
| 378 |
offset_top current top pointer |
offset_top current top pointer |
| 379 |
md pointer to "static" info for the match |
md pointer to "static" info for the match |
| 380 |
ims current /i, /m, and /s options |
ims current /i, /m, and /s options |
| 394 |
*/ |
*/ |
| 395 |
|
|
| 396 |
static int |
static int |
| 397 |
match(REGISTER USPTR eptr, REGISTER const uschar *ecode, const uschar *mstart, |
match(REGISTER USPTR eptr, REGISTER const uschar *ecode, const uschar *mstart, |
| 398 |
int offset_top, match_data *md, unsigned long int ims, eptrblock *eptrb, |
int offset_top, match_data *md, unsigned long int ims, eptrblock *eptrb, |
| 399 |
int flags, unsigned int rdepth) |
int flags, unsigned int rdepth) |
| 400 |
{ |
{ |
| 1266 |
if (eptr != md->start_subject + md->start_offset) RRETURN(MATCH_NOMATCH); |
if (eptr != md->start_subject + md->start_offset) RRETURN(MATCH_NOMATCH); |
| 1267 |
ecode++; |
ecode++; |
| 1268 |
break; |
break; |
| 1269 |
|
|
| 1270 |
/* Reset the start of match point */ |
/* Reset the start of match point */ |
| 1271 |
|
|
| 1272 |
case OP_SET_SOM: |
case OP_SET_SOM: |
| 1273 |
mstart = eptr; |
mstart = eptr; |
| 1274 |
ecode++; |
ecode++; |
| 1275 |
break; |
break; |
| 1276 |
|
|
| 1277 |
/* Assert before internal newline if multiline, or before a terminating |
/* Assert before internal newline if multiline, or before a terminating |
| 1278 |
newline unless endonly is set, else end of subject unless noteol is set. */ |
newline unless endonly is set, else end of subject unless noteol is set. */ |
| 4181 |
md->start_match_ptr = start_match; /* Insurance */ |
md->start_match_ptr = start_match; /* Insurance */ |
| 4182 |
md->match_call_count = 0; |
md->match_call_count = 0; |
| 4183 |
md->eptrn = 0; /* Next free eptrchain slot */ |
md->eptrn = 0; /* Next free eptrchain slot */ |
| 4184 |
rc = match(start_match, md->start_code, start_match, 2, md, |
rc = match(start_match, md->start_code, start_match, 2, md, |
| 4185 |
ims, NULL, 0, 0); |
ims, NULL, 0, 0); |
| 4186 |
|
|
| 4187 |
/* Any return other than MATCH_NOMATCH breaks the loop. */ |
/* Any return other than MATCH_NOMATCH breaks the loop. */ |
| 4263 |
rc = md->offset_overflow? 0 : md->end_offset_top/2; |
rc = md->offset_overflow? 0 : md->end_offset_top/2; |
| 4264 |
|
|
| 4265 |
/* If there is space, set up the whole thing as substring 0. The value of |
/* If there is space, set up the whole thing as substring 0. The value of |
| 4266 |
md->start_match_ptr might be modified if \K was encountered on the success |
md->start_match_ptr might be modified if \K was encountered on the success |
| 4267 |
matching path. */ |
matching path. */ |
| 4268 |
|
|
| 4269 |
if (offsetcount < 2) rc = 0; else |
if (offsetcount < 2) rc = 0; else |