selinux/libselinux
Inseob Kim 30b3e9d25f libselinux: Workaround for heap overhead of pcre
pcre's behavior is changed so that pcre2_match always allocates heap for
match_data, rather than stack, regardless of size. The heap isn't freed
until explicitly calling pcre2_match_data_free. This new behavior may
result in heap overhead, which may increase the peak memory usage about
a few megabytes. It's because regex_match is first called for regex_data
objects, and then regex_data objects are freed at once.

To workaround it, free match_data as soon as we call regex_match. It's
fine because libselinux currently doesn't use match_data, but use only
the return value.

Signed-off-by: Inseob Kim <inseob@google.com>
Acked-by: Jason Zaman <jason@perfinion.com>
2023-01-15 14:17:15 -08:00
..
include libselinux: declare parameter of security_load_policy(3) const 2022-06-15 08:58:48 -04:00
man libselinux: declare parameter of security_load_policy(3) const 2022-06-15 08:58:48 -04:00
src libselinux: Workaround for heap overhead of pcre 2023-01-15 14:17:15 -08:00
utils libselinux: simplify string copying 2022-11-21 14:29:21 -05:00
LICENSE initial import from svn trunk revision 2950 2008-08-19 15:30:36 -04:00
Makefile libselinux: use PCRE2 by default 2021-12-09 11:07:00 -05:00
VERSION Update VERSIONs to 3.5-rc1 for release. 2022-12-22 13:10:26 -08:00