mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
Prevent NULL pointer de-reference.
As a follow up to r279090, if dp hasn't been defined, we shouldn't attempt to do an optimization here.
This commit is contained in:
parent
4c25bba76f
commit
cc3a001f1c
1 changed files with 1 additions and 1 deletions
|
|
@ -244,7 +244,7 @@ matcher(struct re_guts *g,
|
|||
ZAPSTATE(&m->mbs);
|
||||
|
||||
/* Adjust start according to moffset, to speed things up */
|
||||
if (g->moffset > -1)
|
||||
if (dp != NULL && g->moffset > -1)
|
||||
start = ((dp - g->moffset) < start) ? start : dp - g->moffset;
|
||||
|
||||
SP("mloop", m->st, *start);
|
||||
|
|
|
|||
Loading…
Reference in a new issue