mirror of
https://github.com/VectorCamp/vectorscan.git
synced 2025-09-30 03:34:25 +03:00
nfa: standardise callback start, end naming
This commit is contained in:
committed by
Matthew Barr
parent
cf9e40ae1c
commit
9f98f4c7b2
@@ -87,14 +87,14 @@ char ok_and_mark_if_unset(u8 *som_store_valid, struct fatbit *som_set_now,
|
||||
}
|
||||
|
||||
static
|
||||
int somRevCallback(UNUSED u64a som, u64a offset, ReportID id, void *ctx) {
|
||||
DEBUG_PRINTF("offset=%llu, id=%u\n", offset, id);
|
||||
int somRevCallback(UNUSED u64a start, u64a end, ReportID id, void *ctx) {
|
||||
DEBUG_PRINTF("offset=%llu, id=%u\n", end, id);
|
||||
|
||||
// We use the id to store the offset adjustment (for assertions like a
|
||||
// leading \b or multiline mode).
|
||||
assert(id <= 1);
|
||||
u64a *from_offset = ctx;
|
||||
LIMIT_TO_AT_MOST(from_offset, offset + id);
|
||||
LIMIT_TO_AT_MOST(from_offset, end + id);
|
||||
return 1; // continue matching.
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user