summaryrefslogtreecommitdiffstats
path: root/docs/nspr/reference/pr_popiolayer.rst
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 19:33:14 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 19:33:14 +0000
commit36d22d82aa202bb199967e9512281e9a53db42c9 (patch)
tree105e8c98ddea1c1e4784a60a5a6410fa416be2de /docs/nspr/reference/pr_popiolayer.rst
parentInitial commit. (diff)
downloadfirefox-esr-upstream.tar.xz
firefox-esr-upstream.zip
Adding upstream version 115.7.0esr.upstream/115.7.0esrupstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'docs/nspr/reference/pr_popiolayer.rst')
-rw-r--r--docs/nspr/reference/pr_popiolayer.rst53
1 files changed, 53 insertions, 0 deletions
diff --git a/docs/nspr/reference/pr_popiolayer.rst b/docs/nspr/reference/pr_popiolayer.rst
new file mode 100644
index 0000000000..42fae4c074
--- /dev/null
+++ b/docs/nspr/reference/pr_popiolayer.rst
@@ -0,0 +1,53 @@
+PR_PopIOLayer
+=============
+
+Removes a layer from the stack.
+
+
+Syntax
+------
+
+.. code::
+
+ #include <prio.h>
+
+ PRFileDesc *PR_PopIOLayer(
+ PRFileDesc *stack,
+ PRDescIdentity id);
+
+
+Parameters
+~~~~~~~~~~
+
+The function has the following parameters:
+
+``stack``
+ A pointer to a :ref:`PRFileDesc` object representing the stack from
+ which the specified layer is to be removed.
+``id``
+ Identity of the layer to be removed from the stack.
+
+
+Returns
+~~~~~~~
+
+The function returns one of the following values:
+
+- If the layer is successfully removed from the stack, a pointer to the
+ removed layer.
+- If the layer is not found in the stack or cannot be popped (for
+ example, the bottommost layer), the function returns ``NULL`` with
+ the error code ``PR_INVALID_ARGUMENT_ERROR``.
+
+
+Description
+-----------
+
+:ref:`PR_PopIOLayer` pops the specified layer from the stack. If the object
+to be removed is found, :ref:`PR_PopIOLayer` returns a pointer to the
+removed object The object then becomes the responsibility of the caller.
+
+Even if the identity indicates the top layer of the stack, the reference
+returned is not the file descriptor for the stack and that file
+descriptor remains valid. In other words, ``stack`` continues to point
+to the top of the stack after the function returns.