[pcre-dev] [Bug 2520] Error in pcre2_substitute with PCRE2_…

Αρχική Σελίδα
Delete this message
Συντάκτης: admin
Ημερομηνία:  
Προς: pcre-dev
Αντικείμενο: [pcre-dev] [Bug 2520] Error in pcre2_substitute with PCRE2_SUBSTITUTE_MATCHED
https://bugs.exim.org/show_bug.cgi?id=2520

--- Comment #1 from Kilian <kkilger@???> ---
Of course, there is a small "uncertainty" if also "PCRE2_SUBSTITUTE_GLOBAL" is
set. I would favour to disallow the combination of the flags

PCRE2_SUBSITUTE_GLOBAL

and

PCRE2_SUBSTITUTE_MATCHED

because it makes very weird behaviour.

If an error occurs after the second match, the user supplied match_data is
invalidated by the inner match. So if the user tries to "reinvoke"
pcre2_substitute, this won't work.

This is a strong option for providing a second function. If you would share
your code on github, we could change it, create the new function and also
adjust the documentation :-).

--
You are receiving this mail because:
You are on the CC list for the bug.