• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1<html>
2<head>
3<title>pcre2_set_recursion_memory_management specification</title>
4</head>
5<body bgcolor="#FFFFFF" text="#00005A" link="#0066FF" alink="#3399FF" vlink="#2222BB">
6<h1>pcre2_set_recursion_memory_management man page</h1>
7<p>
8Return to the <a href="index.html">PCRE2 index page</a>.
9</p>
10<p>
11This page is part of the PCRE2 HTML documentation. It was generated
12automatically from the original man page. If there is any nonsense in it,
13please consult the man page, in case the conversion went wrong.
14<br>
15<br><b>
16SYNOPSIS
17</b><br>
18<P>
19<b>#include &#60;pcre2.h&#62;</b>
20</P>
21<P>
22<b>int pcre2_set_recursion_memory_management(</b>
23<b>  pcre2_match_context *<i>mcontext</i>,</b>
24<b>  void *(*<i>private_malloc</i>)(PCRE2_SIZE, void *),</b>
25<b>  void (*<i>private_free</i>)(void *, void *), void *<i>memory_data</i>);</b>
26</P>
27<br><b>
28DESCRIPTION
29</b><br>
30<P>
31This function sets the match context fields for custom memory management when
32PCRE2 is compiled to use the heap instead of the system stack for recursive
33function calls while matching. When PCRE2 is compiled to use the stack (the
34default) this function does nothing. The first argument is a match context, the
35second and third specify the memory allocation and freeing functions, and the
36final argument is an opaque value that is passed to them whenever they are
37called. The result of this function is always zero.
38</P>
39<P>
40There is a complete description of the PCRE2 native API in the
41<a href="pcre2api.html"><b>pcre2api</b></a>
42page and a description of the POSIX API in the
43<a href="pcre2posix.html"><b>pcre2posix</b></a>
44page.
45<p>
46Return to the <a href="index.html">PCRE2 index page</a>.
47</p>
48