xref: /aosp_15_r20/external/libxml2/doc/devhelp/libxml2-threads.html (revision 7c5688314b92172186c154356a6374bf7684c3ca)
1*7c568831SAndroid Build Coastguard Worker<html>
2*7c568831SAndroid Build Coastguard Worker<head>
3*7c568831SAndroid Build Coastguard Worker<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
4*7c568831SAndroid Build Coastguard Worker<title>threads: interfaces for thread handling</title>
5*7c568831SAndroid Build Coastguard Worker<meta name="generator" content="Libxml2 devhelp stylesheet">
6*7c568831SAndroid Build Coastguard Worker<link rel="start" href="index.html" title="libxml2 Reference Manual">
7*7c568831SAndroid Build Coastguard Worker<link rel="up" href="general.html" title="API">
8*7c568831SAndroid Build Coastguard Worker<link rel="stylesheet" href="style.css" type="text/css">
9*7c568831SAndroid Build Coastguard Worker<link rel="chapter" href="general.html" title="API">
10*7c568831SAndroid Build Coastguard Worker</head>
11*7c568831SAndroid Build Coastguard Worker<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
12*7c568831SAndroid Build Coastguard Worker<table class="navigation" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2"><tr valign="middle">
13*7c568831SAndroid Build Coastguard Worker<td><a accesskey="p" href="libxml2-schematron.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
14*7c568831SAndroid Build Coastguard Worker<td><a accesskey="u" href="general.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
15*7c568831SAndroid Build Coastguard Worker<td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
16*7c568831SAndroid Build Coastguard Worker<td><a accesskey="n" href="libxml2-tree.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
17*7c568831SAndroid Build Coastguard Worker<th width="100%" align="center">libxml2 Reference Manual</th>
18*7c568831SAndroid Build Coastguard Worker</tr></table>
19*7c568831SAndroid Build Coastguard Worker<h2><span class="refentrytitle">threads</span></h2>
20*7c568831SAndroid Build Coastguard Worker<p>threads - interfaces for thread handling</p>
21*7c568831SAndroid Build Coastguard Worker<p>set of generic threading related routines should work with pthreads, Windows native or TLS threads </p>
22*7c568831SAndroid Build Coastguard Worker<p>Author(s): Daniel Veillard </p>
23*7c568831SAndroid Build Coastguard Worker<div class="refsynopsisdiv">
24*7c568831SAndroid Build Coastguard Worker<h2>Synopsis</h2>
25*7c568831SAndroid Build Coastguard Worker<pre class="synopsis">typedef struct _xmlMutex <a href="#xmlMutex">xmlMutex</a>;
26*7c568831SAndroid Build Coastguard Workertypedef <a href="libxml2-threads.html#xmlMutex">xmlMutex</a> * <a href="#xmlMutexPtr">xmlMutexPtr</a>;
27*7c568831SAndroid Build Coastguard Workertypedef struct _xmlRMutex <a href="#xmlRMutex">xmlRMutex</a>;
28*7c568831SAndroid Build Coastguard Workertypedef <a href="libxml2-threads.html#xmlRMutex">xmlRMutex</a> * <a href="#xmlRMutexPtr">xmlRMutexPtr</a>;
29*7c568831SAndroid Build Coastguard Workerint	<a href="#xmlCheckThreadLocalStorage">xmlCheckThreadLocalStorage</a>	(void);
30*7c568831SAndroid Build Coastguard Workervoid	<a href="#xmlCleanupThreads">xmlCleanupThreads</a>		(void);
31*7c568831SAndroid Build Coastguard Workervoid	<a href="#xmlFreeMutex">xmlFreeMutex</a>			(<a href="libxml2-threads.html#xmlMutexPtr">xmlMutexPtr</a> tok);
32*7c568831SAndroid Build Coastguard Workervoid	<a href="#xmlFreeRMutex">xmlFreeRMutex</a>			(<a href="libxml2-threads.html#xmlRMutexPtr">xmlRMutexPtr</a> tok);
33*7c568831SAndroid Build Coastguard Workerint	<a href="#xmlGetThreadId">xmlGetThreadId</a>			(void);
34*7c568831SAndroid Build Coastguard Workervoid	<a href="#xmlInitThreads">xmlInitThreads</a>			(void);
35*7c568831SAndroid Build Coastguard Workerint	<a href="#xmlIsMainThread">xmlIsMainThread</a>			(void);
36*7c568831SAndroid Build Coastguard Workervoid	<a href="#xmlLockLibrary">xmlLockLibrary</a>			(void);
37*7c568831SAndroid Build Coastguard Workervoid	<a href="#xmlMutexLock">xmlMutexLock</a>			(<a href="libxml2-threads.html#xmlMutexPtr">xmlMutexPtr</a> tok);
38*7c568831SAndroid Build Coastguard Workervoid	<a href="#xmlMutexUnlock">xmlMutexUnlock</a>			(<a href="libxml2-threads.html#xmlMutexPtr">xmlMutexPtr</a> tok);
39*7c568831SAndroid Build Coastguard Worker<a href="libxml2-threads.html#xmlMutexPtr">xmlMutexPtr</a>	<a href="#xmlNewMutex">xmlNewMutex</a>		(void);
40*7c568831SAndroid Build Coastguard Worker<a href="libxml2-threads.html#xmlRMutexPtr">xmlRMutexPtr</a>	<a href="#xmlNewRMutex">xmlNewRMutex</a>		(void);
41*7c568831SAndroid Build Coastguard Workervoid	<a href="#xmlRMutexLock">xmlRMutexLock</a>			(<a href="libxml2-threads.html#xmlRMutexPtr">xmlRMutexPtr</a> tok);
42*7c568831SAndroid Build Coastguard Workervoid	<a href="#xmlRMutexUnlock">xmlRMutexUnlock</a>			(<a href="libxml2-threads.html#xmlRMutexPtr">xmlRMutexPtr</a> tok);
43*7c568831SAndroid Build Coastguard Workervoid	<a href="#xmlUnlockLibrary">xmlUnlockLibrary</a>		(void);
44*7c568831SAndroid Build Coastguard Worker</pre>
45*7c568831SAndroid Build Coastguard Worker</div>
46*7c568831SAndroid Build Coastguard Worker<div class="refsect1" lang="en"><h2>Description</h2></div>
47*7c568831SAndroid Build Coastguard Worker<div class="refsect1" lang="en">
48*7c568831SAndroid Build Coastguard Worker<h2>Details</h2>
49*7c568831SAndroid Build Coastguard Worker<div class="refsect2" lang="en">
50*7c568831SAndroid Build Coastguard Worker<div class="refsect2" lang="en">
51*7c568831SAndroid Build Coastguard Worker<h3>
52*7c568831SAndroid Build Coastguard Worker<a name="xmlMutex">Structure </a>xmlMutex</h3>
53*7c568831SAndroid Build Coastguard Worker<pre class="programlisting">struct _xmlMutex {
54*7c568831SAndroid Build Coastguard WorkerThe content of this structure is not made public by the API.
55*7c568831SAndroid Build Coastguard Worker} xmlMutex;
56*7c568831SAndroid Build Coastguard Worker</pre>
57*7c568831SAndroid Build Coastguard Worker<p></p>
58*7c568831SAndroid Build Coastguard Worker</div>
59*7c568831SAndroid Build Coastguard Worker<hr>
60*7c568831SAndroid Build Coastguard Worker<div class="refsect2" lang="en">
61*7c568831SAndroid Build Coastguard Worker<h3>
62*7c568831SAndroid Build Coastguard Worker<a name="xmlMutexPtr">Typedef </a>xmlMutexPtr</h3>
63*7c568831SAndroid Build Coastguard Worker<pre class="programlisting"><a href="libxml2-threads.html#xmlMutex">xmlMutex</a> * xmlMutexPtr;
64*7c568831SAndroid Build Coastguard Worker</pre>
65*7c568831SAndroid Build Coastguard Worker<p></p>
66*7c568831SAndroid Build Coastguard Worker</div>
67*7c568831SAndroid Build Coastguard Worker<hr>
68*7c568831SAndroid Build Coastguard Worker<div class="refsect2" lang="en">
69*7c568831SAndroid Build Coastguard Worker<h3>
70*7c568831SAndroid Build Coastguard Worker<a name="xmlRMutex">Structure </a>xmlRMutex</h3>
71*7c568831SAndroid Build Coastguard Worker<pre class="programlisting">struct _xmlRMutex {
72*7c568831SAndroid Build Coastguard WorkerThe content of this structure is not made public by the API.
73*7c568831SAndroid Build Coastguard Worker} xmlRMutex;
74*7c568831SAndroid Build Coastguard Worker</pre>
75*7c568831SAndroid Build Coastguard Worker<p></p>
76*7c568831SAndroid Build Coastguard Worker</div>
77*7c568831SAndroid Build Coastguard Worker<hr>
78*7c568831SAndroid Build Coastguard Worker<div class="refsect2" lang="en">
79*7c568831SAndroid Build Coastguard Worker<h3>
80*7c568831SAndroid Build Coastguard Worker<a name="xmlRMutexPtr">Typedef </a>xmlRMutexPtr</h3>
81*7c568831SAndroid Build Coastguard Worker<pre class="programlisting"><a href="libxml2-threads.html#xmlRMutex">xmlRMutex</a> * xmlRMutexPtr;
82*7c568831SAndroid Build Coastguard Worker</pre>
83*7c568831SAndroid Build Coastguard Worker<p></p>
84*7c568831SAndroid Build Coastguard Worker</div>
85*7c568831SAndroid Build Coastguard Worker<hr>
86*7c568831SAndroid Build Coastguard Worker<div class="refsect2" lang="en">
87*7c568831SAndroid Build Coastguard Worker<h3>
88*7c568831SAndroid Build Coastguard Worker<a name="xmlCheckThreadLocalStorage"></a>xmlCheckThreadLocalStorage ()</h3>
89*7c568831SAndroid Build Coastguard Worker<pre class="programlisting">int	xmlCheckThreadLocalStorage	(void)<br>
90*7c568831SAndroid Build Coastguard Worker</pre>
91*7c568831SAndroid Build Coastguard Worker<p>Check whether thread-local storage could be allocated. In cross-platform code running in multithreaded environments, this function should be called once in each thread before calling other library functions to make sure that thread-local storage was allocated properly.</p>
92*7c568831SAndroid Build Coastguard Worker<div class="variablelist"><table border="0">
93*7c568831SAndroid Build Coastguard Worker<col align="left">
94*7c568831SAndroid Build Coastguard Worker<tbody><tr>
95*7c568831SAndroid Build Coastguard Worker<td><span class="term"><i><tt>Returns</tt></i>:</span></td>
96*7c568831SAndroid Build Coastguard Worker<td>0 on success or -1 if a memory allocation failed. A failed allocation signals a typically fatal and irrecoverable out-of-memory situation. Don't call any library functions in this case. This function never fails if the library is compiled with support for thread-local storage. This function never fails for the "main" thread which is the first thread calling <a href="libxml2-parser.html#xmlInitParser">xmlInitParser</a>. Available since v2.12.0.</td>
97*7c568831SAndroid Build Coastguard Worker</tr></tbody>
98*7c568831SAndroid Build Coastguard Worker</table></div>
99*7c568831SAndroid Build Coastguard Worker</div>
100*7c568831SAndroid Build Coastguard Worker<hr>
101*7c568831SAndroid Build Coastguard Worker<div class="refsect2" lang="en">
102*7c568831SAndroid Build Coastguard Worker<h3>
103*7c568831SAndroid Build Coastguard Worker<a name="xmlCleanupThreads"></a>xmlCleanupThreads ()</h3>
104*7c568831SAndroid Build Coastguard Worker<pre class="programlisting">void	xmlCleanupThreads		(void)<br>
105*7c568831SAndroid Build Coastguard Worker</pre>
106*7c568831SAndroid Build Coastguard Worker<p>DEPRECATED: This function is a no-op. Call <a href="libxml2-parser.html#xmlCleanupParser">xmlCleanupParser</a> to free global state but see the warnings there. <a href="libxml2-parser.html#xmlCleanupParser">xmlCleanupParser</a> should be only called once at program exit. In most cases, you don't have call cleanup functions at all.</p>
107*7c568831SAndroid Build Coastguard Worker</div>
108*7c568831SAndroid Build Coastguard Worker<hr>
109*7c568831SAndroid Build Coastguard Worker<div class="refsect2" lang="en">
110*7c568831SAndroid Build Coastguard Worker<h3>
111*7c568831SAndroid Build Coastguard Worker<a name="xmlFreeMutex"></a>xmlFreeMutex ()</h3>
112*7c568831SAndroid Build Coastguard Worker<pre class="programlisting">void	xmlFreeMutex			(<a href="libxml2-threads.html#xmlMutexPtr">xmlMutexPtr</a> tok)<br>
113*7c568831SAndroid Build Coastguard Worker</pre>
114*7c568831SAndroid Build Coastguard Worker<p>Free a mutex.</p>
115*7c568831SAndroid Build Coastguard Worker<div class="variablelist"><table border="0">
116*7c568831SAndroid Build Coastguard Worker<col align="left">
117*7c568831SAndroid Build Coastguard Worker<tbody><tr>
118*7c568831SAndroid Build Coastguard Worker<td><span class="term"><i><tt>tok</tt></i>:</span></td>
119*7c568831SAndroid Build Coastguard Worker<td>the simple mutex</td>
120*7c568831SAndroid Build Coastguard Worker</tr></tbody>
121*7c568831SAndroid Build Coastguard Worker</table></div>
122*7c568831SAndroid Build Coastguard Worker</div>
123*7c568831SAndroid Build Coastguard Worker<hr>
124*7c568831SAndroid Build Coastguard Worker<div class="refsect2" lang="en">
125*7c568831SAndroid Build Coastguard Worker<h3>
126*7c568831SAndroid Build Coastguard Worker<a name="xmlFreeRMutex"></a>xmlFreeRMutex ()</h3>
127*7c568831SAndroid Build Coastguard Worker<pre class="programlisting">void	xmlFreeRMutex			(<a href="libxml2-threads.html#xmlRMutexPtr">xmlRMutexPtr</a> tok)<br>
128*7c568831SAndroid Build Coastguard Worker</pre>
129*7c568831SAndroid Build Coastguard Worker<p>xmlRFreeMutex() is used to reclaim resources associated with a reentrant mutex.</p>
130*7c568831SAndroid Build Coastguard Worker<div class="variablelist"><table border="0">
131*7c568831SAndroid Build Coastguard Worker<col align="left">
132*7c568831SAndroid Build Coastguard Worker<tbody><tr>
133*7c568831SAndroid Build Coastguard Worker<td><span class="term"><i><tt>tok</tt></i>:</span></td>
134*7c568831SAndroid Build Coastguard Worker<td>the reentrant mutex</td>
135*7c568831SAndroid Build Coastguard Worker</tr></tbody>
136*7c568831SAndroid Build Coastguard Worker</table></div>
137*7c568831SAndroid Build Coastguard Worker</div>
138*7c568831SAndroid Build Coastguard Worker<hr>
139*7c568831SAndroid Build Coastguard Worker<div class="refsect2" lang="en">
140*7c568831SAndroid Build Coastguard Worker<h3>
141*7c568831SAndroid Build Coastguard Worker<a name="xmlGetThreadId"></a>xmlGetThreadId ()</h3>
142*7c568831SAndroid Build Coastguard Worker<pre class="programlisting">int	xmlGetThreadId			(void)<br>
143*7c568831SAndroid Build Coastguard Worker</pre>
144*7c568831SAndroid Build Coastguard Worker<p>DEPRECATED: Internal function, do not use. xmlGetThreadId() find the current thread ID number Note that this is likely to be broken on some platforms using pthreads as the specification doesn't mandate pthread_t to be an integer type</p>
145*7c568831SAndroid Build Coastguard Worker<div class="variablelist"><table border="0">
146*7c568831SAndroid Build Coastguard Worker<col align="left">
147*7c568831SAndroid Build Coastguard Worker<tbody><tr>
148*7c568831SAndroid Build Coastguard Worker<td><span class="term"><i><tt>Returns</tt></i>:</span></td>
149*7c568831SAndroid Build Coastguard Worker<td>the current thread ID number</td>
150*7c568831SAndroid Build Coastguard Worker</tr></tbody>
151*7c568831SAndroid Build Coastguard Worker</table></div>
152*7c568831SAndroid Build Coastguard Worker</div>
153*7c568831SAndroid Build Coastguard Worker<hr>
154*7c568831SAndroid Build Coastguard Worker<div class="refsect2" lang="en">
155*7c568831SAndroid Build Coastguard Worker<h3>
156*7c568831SAndroid Build Coastguard Worker<a name="xmlInitThreads"></a>xmlInitThreads ()</h3>
157*7c568831SAndroid Build Coastguard Worker<pre class="programlisting">void	xmlInitThreads			(void)<br>
158*7c568831SAndroid Build Coastguard Worker</pre>
159*7c568831SAndroid Build Coastguard Worker<p>DEPRECATED: Alias for <a href="libxml2-parser.html#xmlInitParser">xmlInitParser</a>.</p>
160*7c568831SAndroid Build Coastguard Worker</div>
161*7c568831SAndroid Build Coastguard Worker<hr>
162*7c568831SAndroid Build Coastguard Worker<div class="refsect2" lang="en">
163*7c568831SAndroid Build Coastguard Worker<h3>
164*7c568831SAndroid Build Coastguard Worker<a name="xmlIsMainThread"></a>xmlIsMainThread ()</h3>
165*7c568831SAndroid Build Coastguard Worker<pre class="programlisting">int	xmlIsMainThread			(void)<br>
166*7c568831SAndroid Build Coastguard Worker</pre>
167*7c568831SAndroid Build Coastguard Worker<p>DEPRECATED: Internal function, do not use. Check whether the current thread is the main thread.</p>
168*7c568831SAndroid Build Coastguard Worker<div class="variablelist"><table border="0">
169*7c568831SAndroid Build Coastguard Worker<col align="left">
170*7c568831SAndroid Build Coastguard Worker<tbody><tr>
171*7c568831SAndroid Build Coastguard Worker<td><span class="term"><i><tt>Returns</tt></i>:</span></td>
172*7c568831SAndroid Build Coastguard Worker<td>1 if the current thread is the main thread, 0 otherwise</td>
173*7c568831SAndroid Build Coastguard Worker</tr></tbody>
174*7c568831SAndroid Build Coastguard Worker</table></div>
175*7c568831SAndroid Build Coastguard Worker</div>
176*7c568831SAndroid Build Coastguard Worker<hr>
177*7c568831SAndroid Build Coastguard Worker<div class="refsect2" lang="en">
178*7c568831SAndroid Build Coastguard Worker<h3>
179*7c568831SAndroid Build Coastguard Worker<a name="xmlLockLibrary"></a>xmlLockLibrary ()</h3>
180*7c568831SAndroid Build Coastguard Worker<pre class="programlisting">void	xmlLockLibrary			(void)<br>
181*7c568831SAndroid Build Coastguard Worker</pre>
182*7c568831SAndroid Build Coastguard Worker<p>xmlLockLibrary() is used to take out a re-entrant lock on the libxml2 library.</p>
183*7c568831SAndroid Build Coastguard Worker</div>
184*7c568831SAndroid Build Coastguard Worker<hr>
185*7c568831SAndroid Build Coastguard Worker<div class="refsect2" lang="en">
186*7c568831SAndroid Build Coastguard Worker<h3>
187*7c568831SAndroid Build Coastguard Worker<a name="xmlMutexLock"></a>xmlMutexLock ()</h3>
188*7c568831SAndroid Build Coastguard Worker<pre class="programlisting">void	xmlMutexLock			(<a href="libxml2-threads.html#xmlMutexPtr">xmlMutexPtr</a> tok)<br>
189*7c568831SAndroid Build Coastguard Worker</pre>
190*7c568831SAndroid Build Coastguard Worker<p>xmlMutexLock() is used to lock a libxml2 token.</p>
191*7c568831SAndroid Build Coastguard Worker<div class="variablelist"><table border="0">
192*7c568831SAndroid Build Coastguard Worker<col align="left">
193*7c568831SAndroid Build Coastguard Worker<tbody><tr>
194*7c568831SAndroid Build Coastguard Worker<td><span class="term"><i><tt>tok</tt></i>:</span></td>
195*7c568831SAndroid Build Coastguard Worker<td>the simple mutex</td>
196*7c568831SAndroid Build Coastguard Worker</tr></tbody>
197*7c568831SAndroid Build Coastguard Worker</table></div>
198*7c568831SAndroid Build Coastguard Worker</div>
199*7c568831SAndroid Build Coastguard Worker<hr>
200*7c568831SAndroid Build Coastguard Worker<div class="refsect2" lang="en">
201*7c568831SAndroid Build Coastguard Worker<h3>
202*7c568831SAndroid Build Coastguard Worker<a name="xmlMutexUnlock"></a>xmlMutexUnlock ()</h3>
203*7c568831SAndroid Build Coastguard Worker<pre class="programlisting">void	xmlMutexUnlock			(<a href="libxml2-threads.html#xmlMutexPtr">xmlMutexPtr</a> tok)<br>
204*7c568831SAndroid Build Coastguard Worker</pre>
205*7c568831SAndroid Build Coastguard Worker<p>xmlMutexUnlock() is used to unlock a libxml2 token.</p>
206*7c568831SAndroid Build Coastguard Worker<div class="variablelist"><table border="0">
207*7c568831SAndroid Build Coastguard Worker<col align="left">
208*7c568831SAndroid Build Coastguard Worker<tbody><tr>
209*7c568831SAndroid Build Coastguard Worker<td><span class="term"><i><tt>tok</tt></i>:</span></td>
210*7c568831SAndroid Build Coastguard Worker<td>the simple mutex</td>
211*7c568831SAndroid Build Coastguard Worker</tr></tbody>
212*7c568831SAndroid Build Coastguard Worker</table></div>
213*7c568831SAndroid Build Coastguard Worker</div>
214*7c568831SAndroid Build Coastguard Worker<hr>
215*7c568831SAndroid Build Coastguard Worker<div class="refsect2" lang="en">
216*7c568831SAndroid Build Coastguard Worker<h3>
217*7c568831SAndroid Build Coastguard Worker<a name="xmlNewMutex"></a>xmlNewMutex ()</h3>
218*7c568831SAndroid Build Coastguard Worker<pre class="programlisting"><a href="libxml2-threads.html#xmlMutexPtr">xmlMutexPtr</a>	xmlNewMutex		(void)<br>
219*7c568831SAndroid Build Coastguard Worker</pre>
220*7c568831SAndroid Build Coastguard Worker<p>xmlNewMutex() is used to allocate a libxml2 token struct for use in synchronizing access to data.</p>
221*7c568831SAndroid Build Coastguard Worker<div class="variablelist"><table border="0">
222*7c568831SAndroid Build Coastguard Worker<col align="left">
223*7c568831SAndroid Build Coastguard Worker<tbody><tr>
224*7c568831SAndroid Build Coastguard Worker<td><span class="term"><i><tt>Returns</tt></i>:</span></td>
225*7c568831SAndroid Build Coastguard Worker<td>a new simple mutex pointer or NULL in case of error</td>
226*7c568831SAndroid Build Coastguard Worker</tr></tbody>
227*7c568831SAndroid Build Coastguard Worker</table></div>
228*7c568831SAndroid Build Coastguard Worker</div>
229*7c568831SAndroid Build Coastguard Worker<hr>
230*7c568831SAndroid Build Coastguard Worker<div class="refsect2" lang="en">
231*7c568831SAndroid Build Coastguard Worker<h3>
232*7c568831SAndroid Build Coastguard Worker<a name="xmlNewRMutex"></a>xmlNewRMutex ()</h3>
233*7c568831SAndroid Build Coastguard Worker<pre class="programlisting"><a href="libxml2-threads.html#xmlRMutexPtr">xmlRMutexPtr</a>	xmlNewRMutex		(void)<br>
234*7c568831SAndroid Build Coastguard Worker</pre>
235*7c568831SAndroid Build Coastguard Worker<p>xmlRNewMutex() is used to allocate a reentrant mutex for use in synchronizing access to data. token_r is a re-entrant lock and thus useful for synchronizing access to data structures that may be manipulated in a recursive fashion.</p>
236*7c568831SAndroid Build Coastguard Worker<div class="variablelist"><table border="0">
237*7c568831SAndroid Build Coastguard Worker<col align="left">
238*7c568831SAndroid Build Coastguard Worker<tbody><tr>
239*7c568831SAndroid Build Coastguard Worker<td><span class="term"><i><tt>Returns</tt></i>:</span></td>
240*7c568831SAndroid Build Coastguard Worker<td>the new reentrant mutex pointer or NULL in case of error</td>
241*7c568831SAndroid Build Coastguard Worker</tr></tbody>
242*7c568831SAndroid Build Coastguard Worker</table></div>
243*7c568831SAndroid Build Coastguard Worker</div>
244*7c568831SAndroid Build Coastguard Worker<hr>
245*7c568831SAndroid Build Coastguard Worker<div class="refsect2" lang="en">
246*7c568831SAndroid Build Coastguard Worker<h3>
247*7c568831SAndroid Build Coastguard Worker<a name="xmlRMutexLock"></a>xmlRMutexLock ()</h3>
248*7c568831SAndroid Build Coastguard Worker<pre class="programlisting">void	xmlRMutexLock			(<a href="libxml2-threads.html#xmlRMutexPtr">xmlRMutexPtr</a> tok)<br>
249*7c568831SAndroid Build Coastguard Worker</pre>
250*7c568831SAndroid Build Coastguard Worker<p>xmlRMutexLock() is used to lock a libxml2 token_r.</p>
251*7c568831SAndroid Build Coastguard Worker<div class="variablelist"><table border="0">
252*7c568831SAndroid Build Coastguard Worker<col align="left">
253*7c568831SAndroid Build Coastguard Worker<tbody><tr>
254*7c568831SAndroid Build Coastguard Worker<td><span class="term"><i><tt>tok</tt></i>:</span></td>
255*7c568831SAndroid Build Coastguard Worker<td>the reentrant mutex</td>
256*7c568831SAndroid Build Coastguard Worker</tr></tbody>
257*7c568831SAndroid Build Coastguard Worker</table></div>
258*7c568831SAndroid Build Coastguard Worker</div>
259*7c568831SAndroid Build Coastguard Worker<hr>
260*7c568831SAndroid Build Coastguard Worker<div class="refsect2" lang="en">
261*7c568831SAndroid Build Coastguard Worker<h3>
262*7c568831SAndroid Build Coastguard Worker<a name="xmlRMutexUnlock"></a>xmlRMutexUnlock ()</h3>
263*7c568831SAndroid Build Coastguard Worker<pre class="programlisting">void	xmlRMutexUnlock			(<a href="libxml2-threads.html#xmlRMutexPtr">xmlRMutexPtr</a> tok)<br>
264*7c568831SAndroid Build Coastguard Worker</pre>
265*7c568831SAndroid Build Coastguard Worker<p>xmlRMutexUnlock() is used to unlock a libxml2 token_r.</p>
266*7c568831SAndroid Build Coastguard Worker<div class="variablelist"><table border="0">
267*7c568831SAndroid Build Coastguard Worker<col align="left">
268*7c568831SAndroid Build Coastguard Worker<tbody><tr>
269*7c568831SAndroid Build Coastguard Worker<td><span class="term"><i><tt>tok</tt></i>:</span></td>
270*7c568831SAndroid Build Coastguard Worker<td>the reentrant mutex</td>
271*7c568831SAndroid Build Coastguard Worker</tr></tbody>
272*7c568831SAndroid Build Coastguard Worker</table></div>
273*7c568831SAndroid Build Coastguard Worker</div>
274*7c568831SAndroid Build Coastguard Worker<hr>
275*7c568831SAndroid Build Coastguard Worker<div class="refsect2" lang="en">
276*7c568831SAndroid Build Coastguard Worker<h3>
277*7c568831SAndroid Build Coastguard Worker<a name="xmlUnlockLibrary"></a>xmlUnlockLibrary ()</h3>
278*7c568831SAndroid Build Coastguard Worker<pre class="programlisting">void	xmlUnlockLibrary		(void)<br>
279*7c568831SAndroid Build Coastguard Worker</pre>
280*7c568831SAndroid Build Coastguard Worker<p>xmlUnlockLibrary() is used to release a re-entrant lock on the libxml2 library.</p>
281*7c568831SAndroid Build Coastguard Worker</div>
282*7c568831SAndroid Build Coastguard Worker<hr>
283*7c568831SAndroid Build Coastguard Worker</div>
284*7c568831SAndroid Build Coastguard Worker</div>
285*7c568831SAndroid Build Coastguard Worker</body>
286*7c568831SAndroid Build Coastguard Worker</html>
287