summaryrefslogtreecommitdiffstats
path: root/docs/nspr/reference/pr_newlock.rst
blob: 7fbc51348ed3706544014ae67def7c0788764571 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
PR_NewLock
==========

Creates a new lock.


Syntax
------

.. code::

   #include <prlock.h>

   PRLock* PR_NewLock(void);


Returns
~~~~~~~

The function returns one of the following values:

-  If successful, a pointer to the new lock object.
-  If unsuccessful (for example, the lock cannot be created because of
   resource constraints), ``NULL``.


Description
-----------

:ref:`PR_NewLock` creates a new opaque lock.