| <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> |
| <html> |
| <head> |
| <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> |
| <title>GUnixFDList: GIO Reference Manual</title> |
| <meta name="generator" content="DocBook XSL Stylesheets V1.79.1"> |
| <link rel="home" href="index.html" title="GIO Reference Manual"> |
| <link rel="up" href="networking.html" title="Low-level network support"> |
| <link rel="prev" href="GSocketControlMessage.html" title="GSocketControlMessage"> |
| <link rel="next" href="GUnixFDMessage.html" title="GUnixFDMessage"> |
| <meta name="generator" content="GTK-Doc V1.25.1 (XML mode)"> |
| <link rel="stylesheet" href="style.css" type="text/css"> |
| </head> |
| <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"> |
| <table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="5"><tr valign="middle"> |
| <td width="100%" align="left" class="shortcuts"> |
| <a href="#" class="shortcut">Top</a><span id="nav_description"> <span class="dim">|</span> |
| <a href="#GUnixFDList.description" class="shortcut">Description</a></span><span id="nav_hierarchy"> <span class="dim">|</span> |
| <a href="#GUnixFDList.object-hierarchy" class="shortcut">Object Hierarchy</a></span> |
| </td> |
| <td><a accesskey="h" href="index.html"><img src="home.png" width="16" height="16" border="0" alt="Home"></a></td> |
| <td><a accesskey="u" href="networking.html"><img src="up.png" width="16" height="16" border="0" alt="Up"></a></td> |
| <td><a accesskey="p" href="GSocketControlMessage.html"><img src="left.png" width="16" height="16" border="0" alt="Prev"></a></td> |
| <td><a accesskey="n" href="GUnixFDMessage.html"><img src="right.png" width="16" height="16" border="0" alt="Next"></a></td> |
| </tr></table> |
| <div class="refentry"> |
| <a name="GUnixFDList"></a><div class="titlepage"></div> |
| <div class="refnamediv"><table width="100%"><tr> |
| <td valign="top"> |
| <h2><span class="refentrytitle"><a name="GUnixFDList.top_of_page"></a>GUnixFDList</span></h2> |
| <p>GUnixFDList — An object containing a set of UNIX file descriptors</p> |
| </td> |
| <td class="gallery_image" valign="top" align="right"></td> |
| </tr></table></div> |
| <div class="refsect1"> |
| <a name="GUnixFDList.functions"></a><h2>Functions</h2> |
| <div class="informaltable"><table class="informaltable" width="100%" border="0"> |
| <colgroup> |
| <col width="150px" class="functions_return"> |
| <col class="functions_name"> |
| </colgroup> |
| <tbody> |
| <tr> |
| <td class="function_type"> |
| <a class="link" href="GUnixFDList.html" title="GUnixFDList"><span class="returnvalue">GUnixFDList</span></a> * |
| </td> |
| <td class="function_name"> |
| <a class="link" href="GUnixFDList.html#g-unix-fd-list-new-from-array" title="g_unix_fd_list_new_from_array ()">g_unix_fd_list_new_from_array</a> <span class="c_punctuation">()</span> |
| </td> |
| </tr> |
| <tr> |
| <td class="function_type"> |
| <a class="link" href="GUnixFDList.html" title="GUnixFDList"><span class="returnvalue">GUnixFDList</span></a> * |
| </td> |
| <td class="function_name"> |
| <a class="link" href="GUnixFDList.html#g-unix-fd-list-new" title="g_unix_fd_list_new ()">g_unix_fd_list_new</a> <span class="c_punctuation">()</span> |
| </td> |
| </tr> |
| <tr> |
| <td class="function_type"> |
| <a href="../glib-Basic-Types.html#gint"><span class="returnvalue">gint</span></a> |
| </td> |
| <td class="function_name"> |
| <a class="link" href="GUnixFDList.html#g-unix-fd-list-get-length" title="g_unix_fd_list_get_length ()">g_unix_fd_list_get_length</a> <span class="c_punctuation">()</span> |
| </td> |
| </tr> |
| <tr> |
| <td class="function_type"> |
| <a href="../glib-Basic-Types.html#gint"><span class="returnvalue">gint</span></a> |
| </td> |
| <td class="function_name"> |
| <a class="link" href="GUnixFDList.html#g-unix-fd-list-get" title="g_unix_fd_list_get ()">g_unix_fd_list_get</a> <span class="c_punctuation">()</span> |
| </td> |
| </tr> |
| <tr> |
| <td class="function_type">const <a href="../glib-Basic-Types.html#gint"><span class="returnvalue">gint</span></a> * |
| </td> |
| <td class="function_name"> |
| <a class="link" href="GUnixFDList.html#g-unix-fd-list-peek-fds" title="g_unix_fd_list_peek_fds ()">g_unix_fd_list_peek_fds</a> <span class="c_punctuation">()</span> |
| </td> |
| </tr> |
| <tr> |
| <td class="function_type"> |
| <a href="../glib-Basic-Types.html#gint"><span class="returnvalue">gint</span></a> * |
| </td> |
| <td class="function_name"> |
| <a class="link" href="GUnixFDList.html#g-unix-fd-list-steal-fds" title="g_unix_fd_list_steal_fds ()">g_unix_fd_list_steal_fds</a> <span class="c_punctuation">()</span> |
| </td> |
| </tr> |
| <tr> |
| <td class="function_type"> |
| <a href="../glib-Basic-Types.html#gint"><span class="returnvalue">gint</span></a> |
| </td> |
| <td class="function_name"> |
| <a class="link" href="GUnixFDList.html#g-unix-fd-list-append" title="g_unix_fd_list_append ()">g_unix_fd_list_append</a> <span class="c_punctuation">()</span> |
| </td> |
| </tr> |
| </tbody> |
| </table></div> |
| </div> |
| <div class="refsect1"> |
| <a name="GUnixFDList.other"></a><h2>Types and Values</h2> |
| <div class="informaltable"><table class="informaltable" width="100%" border="0"> |
| <colgroup> |
| <col width="150px" class="name"> |
| <col class="description"> |
| </colgroup> |
| <tbody><tr> |
| <td class="datatype_keyword"> </td> |
| <td class="function_name"><a class="link" href="GUnixFDList.html#GUnixFDList-struct" title="GUnixFDList">GUnixFDList</a></td> |
| </tr></tbody> |
| </table></div> |
| </div> |
| <div class="refsect1"> |
| <a name="GUnixFDList.object-hierarchy"></a><h2>Object Hierarchy</h2> |
| <pre class="screen"> <a href="../gobject-The-Base-Object-Type.html#GObject-struct">GObject</a> |
| <span class="lineart">╰──</span> GUnixFDList |
| </pre> |
| </div> |
| <div class="refsect1"> |
| <a name="GUnixFDList.includes"></a><h2>Includes</h2> |
| <pre class="synopsis">#include <gio/gunixfdlist.h> |
| </pre> |
| </div> |
| <div class="refsect1"> |
| <a name="GUnixFDList.description"></a><h2>Description</h2> |
| <p>A <a class="link" href="GUnixFDList.html" title="GUnixFDList"><span class="type">GUnixFDList</span></a> contains a list of file descriptors. It owns the file |
| descriptors that it contains, closing them when finalized.</p> |
| <p>It may be wrapped in a <a class="link" href="GUnixFDMessage.html" title="GUnixFDMessage"><span class="type">GUnixFDMessage</span></a> and sent over a <a class="link" href="GSocket.html" title="GSocket"><span class="type">GSocket</span></a> in |
| the <code class="literal">G_SOCKET_ADDRESS_UNIX</code> family by using <a class="link" href="GSocket.html#g-socket-send-message" title="g_socket_send_message ()"><code class="function">g_socket_send_message()</code></a> |
| and received using <a class="link" href="GSocket.html#g-socket-receive-message" title="g_socket_receive_message ()"><code class="function">g_socket_receive_message()</code></a>.</p> |
| <p>Note that <code class="literal"><gio/gunixfdlist.h></code> belongs to the UNIX-specific GIO |
| interfaces, thus you have to use the <code class="literal">gio-unix-2.0.pc</code> pkg-config |
| file when using it.</p> |
| </div> |
| <div class="refsect1"> |
| <a name="GUnixFDList.functions_details"></a><h2>Functions</h2> |
| <div class="refsect2"> |
| <a name="g-unix-fd-list-new-from-array"></a><h3>g_unix_fd_list_new_from_array ()</h3> |
| <pre class="programlisting"><a class="link" href="GUnixFDList.html" title="GUnixFDList"><span class="returnvalue">GUnixFDList</span></a> * |
| g_unix_fd_list_new_from_array (<em class="parameter"><code>const <a href="../glib-Basic-Types.html#gint"><span class="type">gint</span></a> *fds</code></em>, |
| <em class="parameter"><code><a href="../glib-Basic-Types.html#gint"><span class="type">gint</span></a> n_fds</code></em>);</pre> |
| <p>Creates a new <a class="link" href="GUnixFDList.html" title="GUnixFDList"><span class="type">GUnixFDList</span></a> containing the file descriptors given in |
| <em class="parameter"><code>fds</code></em> |
| . The file descriptors become the property of the new list and |
| may no longer be used by the caller. The array itself is owned by |
| the caller.</p> |
| <p>Each file descriptor in the array should be set to close-on-exec.</p> |
| <p>If <em class="parameter"><code>n_fds</code></em> |
| is -1 then <em class="parameter"><code>fds</code></em> |
| must be terminated with -1.</p> |
| <div class="refsect3"> |
| <a name="g-unix-fd-list-new-from-array.parameters"></a><h4>Parameters</h4> |
| <div class="informaltable"><table class="informaltable" width="100%" border="0"> |
| <colgroup> |
| <col width="150px" class="parameters_name"> |
| <col class="parameters_description"> |
| <col width="200px" class="parameters_annotations"> |
| </colgroup> |
| <tbody> |
| <tr> |
| <td class="parameter_name"><p>fds</p></td> |
| <td class="parameter_description"><p> the initial list of file descriptors. </p></td> |
| <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> length=n_fds]</span></td> |
| </tr> |
| <tr> |
| <td class="parameter_name"><p>n_fds</p></td> |
| <td class="parameter_description"><p>the length of <span class="type">fds</span>, or -1</p></td> |
| <td class="parameter_annotations"> </td> |
| </tr> |
| </tbody> |
| </table></div> |
| </div> |
| <div class="refsect3"> |
| <a name="g-unix-fd-list-new-from-array.returns"></a><h4>Returns</h4> |
| <p> a new <a class="link" href="GUnixFDList.html" title="GUnixFDList"><span class="type">GUnixFDList</span></a></p> |
| </div> |
| <p class="since">Since: <a class="link" href="api-index-2-24.html#api-index-2.24">2.24</a></p> |
| </div> |
| <hr> |
| <div class="refsect2"> |
| <a name="g-unix-fd-list-new"></a><h3>g_unix_fd_list_new ()</h3> |
| <pre class="programlisting"><a class="link" href="GUnixFDList.html" title="GUnixFDList"><span class="returnvalue">GUnixFDList</span></a> * |
| g_unix_fd_list_new (<em class="parameter"><code><span class="type">void</span></code></em>);</pre> |
| <p>Creates a new <a class="link" href="GUnixFDList.html" title="GUnixFDList"><span class="type">GUnixFDList</span></a> containing no file descriptors.</p> |
| <div class="refsect3"> |
| <a name="g-unix-fd-list-new.returns"></a><h4>Returns</h4> |
| <p> a new <a class="link" href="GUnixFDList.html" title="GUnixFDList"><span class="type">GUnixFDList</span></a></p> |
| </div> |
| <p class="since">Since: <a class="link" href="api-index-2-24.html#api-index-2.24">2.24</a></p> |
| </div> |
| <hr> |
| <div class="refsect2"> |
| <a name="g-unix-fd-list-get-length"></a><h3>g_unix_fd_list_get_length ()</h3> |
| <pre class="programlisting"><a href="../glib-Basic-Types.html#gint"><span class="returnvalue">gint</span></a> |
| g_unix_fd_list_get_length (<em class="parameter"><code><a class="link" href="GUnixFDList.html" title="GUnixFDList"><span class="type">GUnixFDList</span></a> *list</code></em>);</pre> |
| <p>Gets the length of <em class="parameter"><code>list</code></em> |
| (ie: the number of file descriptors |
| contained within).</p> |
| <div class="refsect3"> |
| <a name="g-unix-fd-list-get-length.parameters"></a><h4>Parameters</h4> |
| <div class="informaltable"><table class="informaltable" width="100%" border="0"> |
| <colgroup> |
| <col width="150px" class="parameters_name"> |
| <col class="parameters_description"> |
| <col width="200px" class="parameters_annotations"> |
| </colgroup> |
| <tbody><tr> |
| <td class="parameter_name"><p>list</p></td> |
| <td class="parameter_description"><p>a <a class="link" href="GUnixFDList.html" title="GUnixFDList"><span class="type">GUnixFDList</span></a></p></td> |
| <td class="parameter_annotations"> </td> |
| </tr></tbody> |
| </table></div> |
| </div> |
| <div class="refsect3"> |
| <a name="g-unix-fd-list-get-length.returns"></a><h4>Returns</h4> |
| <p> the length of <em class="parameter"><code>list</code></em> |
| </p> |
| </div> |
| <p class="since">Since: <a class="link" href="api-index-2-24.html#api-index-2.24">2.24</a></p> |
| </div> |
| <hr> |
| <div class="refsect2"> |
| <a name="g-unix-fd-list-get"></a><h3>g_unix_fd_list_get ()</h3> |
| <pre class="programlisting"><a href="../glib-Basic-Types.html#gint"><span class="returnvalue">gint</span></a> |
| g_unix_fd_list_get (<em class="parameter"><code><a class="link" href="GUnixFDList.html" title="GUnixFDList"><span class="type">GUnixFDList</span></a> *list</code></em>, |
| <em class="parameter"><code><a href="../glib-Basic-Types.html#gint"><span class="type">gint</span></a> index_</code></em>, |
| <em class="parameter"><code><a href="../glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre> |
| <p>Gets a file descriptor out of <em class="parameter"><code>list</code></em> |
| .</p> |
| <p><em class="parameter"><code>index_</code></em> |
| specifies the index of the file descriptor to get. It is a |
| programmer error for <em class="parameter"><code>index_</code></em> |
| to be out of range; see |
| <a class="link" href="GUnixFDList.html#g-unix-fd-list-get-length" title="g_unix_fd_list_get_length ()"><code class="function">g_unix_fd_list_get_length()</code></a>.</p> |
| <p>The file descriptor is duplicated using <code class="function">dup()</code> and set as |
| close-on-exec before being returned. You must call <code class="function">close()</code> on it |
| when you are done.</p> |
| <p>A possible cause of failure is exceeding the per-process or |
| system-wide file descriptor limit.</p> |
| <div class="refsect3"> |
| <a name="g-unix-fd-list-get.parameters"></a><h4>Parameters</h4> |
| <div class="informaltable"><table class="informaltable" width="100%" border="0"> |
| <colgroup> |
| <col width="150px" class="parameters_name"> |
| <col class="parameters_description"> |
| <col width="200px" class="parameters_annotations"> |
| </colgroup> |
| <tbody> |
| <tr> |
| <td class="parameter_name"><p>list</p></td> |
| <td class="parameter_description"><p>a <a class="link" href="GUnixFDList.html" title="GUnixFDList"><span class="type">GUnixFDList</span></a></p></td> |
| <td class="parameter_annotations"> </td> |
| </tr> |
| <tr> |
| <td class="parameter_name"><p>index_</p></td> |
| <td class="parameter_description"><p>the index into the list</p></td> |
| <td class="parameter_annotations"> </td> |
| </tr> |
| <tr> |
| <td class="parameter_name"><p>error</p></td> |
| <td class="parameter_description"><p>a <a href="../glib-Error-Reporting.html#GError"><span class="type">GError</span></a> pointer</p></td> |
| <td class="parameter_annotations"> </td> |
| </tr> |
| </tbody> |
| </table></div> |
| </div> |
| <div class="refsect3"> |
| <a name="g-unix-fd-list-get.returns"></a><h4>Returns</h4> |
| <p> the file descriptor, or -1 in case of error</p> |
| </div> |
| <p class="since">Since: <a class="link" href="api-index-2-24.html#api-index-2.24">2.24</a></p> |
| </div> |
| <hr> |
| <div class="refsect2"> |
| <a name="g-unix-fd-list-peek-fds"></a><h3>g_unix_fd_list_peek_fds ()</h3> |
| <pre class="programlisting">const <a href="../glib-Basic-Types.html#gint"><span class="returnvalue">gint</span></a> * |
| g_unix_fd_list_peek_fds (<em class="parameter"><code><a class="link" href="GUnixFDList.html" title="GUnixFDList"><span class="type">GUnixFDList</span></a> *list</code></em>, |
| <em class="parameter"><code><a href="../glib-Basic-Types.html#gint"><span class="type">gint</span></a> *length</code></em>);</pre> |
| <p>Returns the array of file descriptors that is contained in this |
| object.</p> |
| <p>After this call, the descriptors remain the property of <em class="parameter"><code>list</code></em> |
| . The |
| caller must not close them and must not free the array. The array is |
| valid only until <em class="parameter"><code>list</code></em> |
| is changed in any way.</p> |
| <p>If <em class="parameter"><code>length</code></em> |
| is non-<a href="../glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> then it is set to the number of file |
| descriptors in the returned array. The returned array is also |
| terminated with -1.</p> |
| <p>This function never returns <a href="../glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. In case there are no file |
| descriptors contained in <em class="parameter"><code>list</code></em> |
| , an empty array is returned.</p> |
| <div class="refsect3"> |
| <a name="g-unix-fd-list-peek-fds.parameters"></a><h4>Parameters</h4> |
| <div class="informaltable"><table class="informaltable" width="100%" border="0"> |
| <colgroup> |
| <col width="150px" class="parameters_name"> |
| <col class="parameters_description"> |
| <col width="200px" class="parameters_annotations"> |
| </colgroup> |
| <tbody> |
| <tr> |
| <td class="parameter_name"><p>list</p></td> |
| <td class="parameter_description"><p>a <a class="link" href="GUnixFDList.html" title="GUnixFDList"><span class="type">GUnixFDList</span></a></p></td> |
| <td class="parameter_annotations"> </td> |
| </tr> |
| <tr> |
| <td class="parameter_name"><p>length</p></td> |
| <td class="parameter_description"><p> pointer to the length of the returned |
| array, or <a href="../glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. </p></td> |
| <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td> |
| </tr> |
| </tbody> |
| </table></div> |
| </div> |
| <div class="refsect3"> |
| <a name="g-unix-fd-list-peek-fds.returns"></a><h4>Returns</h4> |
| <p> an array of file |
| descriptors. </p> |
| <p><span class="annotation">[<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> length=length][<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>]</span></p> |
| </div> |
| <p class="since">Since: <a class="link" href="api-index-2-24.html#api-index-2.24">2.24</a></p> |
| </div> |
| <hr> |
| <div class="refsect2"> |
| <a name="g-unix-fd-list-steal-fds"></a><h3>g_unix_fd_list_steal_fds ()</h3> |
| <pre class="programlisting"><a href="../glib-Basic-Types.html#gint"><span class="returnvalue">gint</span></a> * |
| g_unix_fd_list_steal_fds (<em class="parameter"><code><a class="link" href="GUnixFDList.html" title="GUnixFDList"><span class="type">GUnixFDList</span></a> *list</code></em>, |
| <em class="parameter"><code><a href="../glib-Basic-Types.html#gint"><span class="type">gint</span></a> *length</code></em>);</pre> |
| <p>Returns the array of file descriptors that is contained in this |
| object.</p> |
| <p>After this call, the descriptors are no longer contained in |
| <em class="parameter"><code>list</code></em> |
| . Further calls will return an empty list (unless more |
| descriptors have been added).</p> |
| <p>The return result of this function must be freed with <a href="../glib-Memory-Allocation.html#g-free"><code class="function">g_free()</code></a>. |
| The caller is also responsible for closing all of the file |
| descriptors. The file descriptors in the array are set to |
| close-on-exec.</p> |
| <p>If <em class="parameter"><code>length</code></em> |
| is non-<a href="../glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> then it is set to the number of file |
| descriptors in the returned array. The returned array is also |
| terminated with -1.</p> |
| <p>This function never returns <a href="../glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. In case there are no file |
| descriptors contained in <em class="parameter"><code>list</code></em> |
| , an empty array is returned.</p> |
| <div class="refsect3"> |
| <a name="g-unix-fd-list-steal-fds.parameters"></a><h4>Parameters</h4> |
| <div class="informaltable"><table class="informaltable" width="100%" border="0"> |
| <colgroup> |
| <col width="150px" class="parameters_name"> |
| <col class="parameters_description"> |
| <col width="200px" class="parameters_annotations"> |
| </colgroup> |
| <tbody> |
| <tr> |
| <td class="parameter_name"><p>list</p></td> |
| <td class="parameter_description"><p>a <a class="link" href="GUnixFDList.html" title="GUnixFDList"><span class="type">GUnixFDList</span></a></p></td> |
| <td class="parameter_annotations"> </td> |
| </tr> |
| <tr> |
| <td class="parameter_name"><p>length</p></td> |
| <td class="parameter_description"><p> pointer to the length of the returned |
| array, or <a href="../glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. </p></td> |
| <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td> |
| </tr> |
| </tbody> |
| </table></div> |
| </div> |
| <div class="refsect3"> |
| <a name="g-unix-fd-list-steal-fds.returns"></a><h4>Returns</h4> |
| <p> an array of file |
| descriptors. </p> |
| <p><span class="annotation">[<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> length=length][<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></p> |
| </div> |
| <p class="since">Since: <a class="link" href="api-index-2-24.html#api-index-2.24">2.24</a></p> |
| </div> |
| <hr> |
| <div class="refsect2"> |
| <a name="g-unix-fd-list-append"></a><h3>g_unix_fd_list_append ()</h3> |
| <pre class="programlisting"><a href="../glib-Basic-Types.html#gint"><span class="returnvalue">gint</span></a> |
| g_unix_fd_list_append (<em class="parameter"><code><a class="link" href="GUnixFDList.html" title="GUnixFDList"><span class="type">GUnixFDList</span></a> *list</code></em>, |
| <em class="parameter"><code><a href="../glib-Basic-Types.html#gint"><span class="type">gint</span></a> fd</code></em>, |
| <em class="parameter"><code><a href="../glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre> |
| <p>Adds a file descriptor to <em class="parameter"><code>list</code></em> |
| .</p> |
| <p>The file descriptor is duplicated using <code class="function">dup()</code>. You keep your copy |
| of the descriptor and the copy contained in <em class="parameter"><code>list</code></em> |
| will be closed |
| when <em class="parameter"><code>list</code></em> |
| is finalized.</p> |
| <p>A possible cause of failure is exceeding the per-process or |
| system-wide file descriptor limit.</p> |
| <p>The index of the file descriptor in the list is returned. If you use |
| this index with <a class="link" href="GUnixFDList.html#g-unix-fd-list-get" title="g_unix_fd_list_get ()"><code class="function">g_unix_fd_list_get()</code></a> then you will receive back a |
| duplicated copy of the same file descriptor.</p> |
| <div class="refsect3"> |
| <a name="g-unix-fd-list-append.parameters"></a><h4>Parameters</h4> |
| <div class="informaltable"><table class="informaltable" width="100%" border="0"> |
| <colgroup> |
| <col width="150px" class="parameters_name"> |
| <col class="parameters_description"> |
| <col width="200px" class="parameters_annotations"> |
| </colgroup> |
| <tbody> |
| <tr> |
| <td class="parameter_name"><p>list</p></td> |
| <td class="parameter_description"><p>a <a class="link" href="GUnixFDList.html" title="GUnixFDList"><span class="type">GUnixFDList</span></a></p></td> |
| <td class="parameter_annotations"> </td> |
| </tr> |
| <tr> |
| <td class="parameter_name"><p>fd</p></td> |
| <td class="parameter_description"><p>a valid open file descriptor</p></td> |
| <td class="parameter_annotations"> </td> |
| </tr> |
| <tr> |
| <td class="parameter_name"><p>error</p></td> |
| <td class="parameter_description"><p>a <a href="../glib-Error-Reporting.html#GError"><span class="type">GError</span></a> pointer</p></td> |
| <td class="parameter_annotations"> </td> |
| </tr> |
| </tbody> |
| </table></div> |
| </div> |
| <div class="refsect3"> |
| <a name="g-unix-fd-list-append.returns"></a><h4>Returns</h4> |
| <p> the index of the appended fd in case of success, else -1 |
| (and <em class="parameter"><code>error</code></em> |
| is set)</p> |
| </div> |
| <p class="since">Since: <a class="link" href="api-index-2-24.html#api-index-2.24">2.24</a></p> |
| </div> |
| </div> |
| <div class="refsect1"> |
| <a name="GUnixFDList.other_details"></a><h2>Types and Values</h2> |
| <div class="refsect2"> |
| <a name="GUnixFDList-struct"></a><h3>GUnixFDList</h3> |
| <pre class="programlisting">typedef struct _GUnixFDList GUnixFDList;</pre> |
| <p><a class="link" href="GUnixFDList.html" title="GUnixFDList"><span class="type">GUnixFDList</span></a> is an opaque data structure and can only be accessed |
| using the following functions.</p> |
| </div> |
| </div> |
| <div class="refsect1"> |
| <a name="GUnixFDList.see-also"></a><h2>See Also</h2> |
| <p><a class="link" href="GUnixFDMessage.html" title="GUnixFDMessage"><span class="type">GUnixFDMessage</span></a></p> |
| </div> |
| </div> |
| <div class="footer"> |
| <hr>Generated by GTK-Doc V1.25.1</div> |
| </body> |
| </html> |