Skip to content

Conversation

@vpiserchia
Copy link

In this way the hs_compile_multi will return the identifier of the regexp matched.
By default it's a list of zeros, that is do not return the identifier.

@vpiserchia vpiserchia closed this Feb 10, 2017
@vpiserchia vpiserchia deleted the patterns_ids branch February 10, 2017 07:48
@vpiserchia vpiserchia restored the patterns_ids branch February 10, 2017 12:04
@vpiserchia vpiserchia reopened this Feb 10, 2017
mode = self._hs.HS_MODE_BLOCK

if ids is None:
ids = [0] * len(patterns)
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What do you think about making the default a NULL pointer here instead of replicating Hyperscan's default? Seems more robust to me even if you'd have to special case it in _CompilePatterns then.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants