[pcre-dev] [Bug 1174] allow passing of pcre_{malloc, free, …

Top Page
Delete this message
Author: Philip Hazel
Date:  
To: pcre-dev
Subject: [pcre-dev] [Bug 1174] allow passing of pcre_{malloc, free, stack_malloc, stack_free, callout} as parameters
------- You are receiving this mail because: -------
You are on the CC list for the bug.

http://bugs.exim.org/show_bug.cgi?id=1174




--- Comment #2 from Philip Hazel <ph10@???> 2011-11-08 09:35:27 ---
An alternative idea, which is less disruptive to the interface, would be to
invent a new compile-time option called PCRE_USE_MALLOC. This would cause all
the various functions (at compile time and run time) to use the standard
malloc() and free() functions instead of those in the static variables. The
callout function for pcre_exec() could be added to the extra data to override
the static value. This solution has the virtue of needing no changes to the
pcre_get_xxx() function interfaces. However, it is of course not fully general.
But would it meet your needs?


--
Configure bugmail: http://bugs.exim.org/userprefs.cgi?tab=email