Branch: Tag:


2008-05-12 12:37:48 by Martin Stjernholm <>

Documented query_address and synched up the code with the one in Fd.

Rev: src/modules/files/socket.c:1.98

2303:   <dt class='head--type'><span class='homogen--type'>Method</span>   <span class='homogen--name'><b>query_address</b></span>   </dt> - <dd><p><code><code class='datatype'>string</code> <b><span class='method'>query_address</span>(</b><code class='datatype'>string</code> <code class='argument'>arg1</code><b>)</b></code></p></dd> - <dt class='head--fixme'>FIXME</dt> - <dd class='body--fixme'><p>Document this function.</p> + <dd><p><code><code class='datatype'>string</code> <b><span class='method'>query_address</span>(</b><b>)</b></code></p></dd> +  + <dt class='head--doc'>Description</dt> + <dd class='body--doc'><p>Get the address and port of the local socket end-point.</p> + </dd> + <dt class='head--doc'>Returns</dt> + <dd class='body--doc'><p>This function returns the address and port of a socket end-point +  on the form <code class='expr'>"x.x.x.x&nbsp;port"</code> (IPv4) or +  <code class='expr'>"x:x:x:x:x:x:x:x&nbsp;port"</code> (IPv6).</p> + <p> If there is some error querying or formatting the address, +  <code class='expr'>0</code> (zero) is returned and <code>errno()</code> will return the +  error code.</p> + </dd> + <dt class='head--doc'>Throws</dt> + <dd class='body--doc'><p>An error is thrown if the socket isn't bound.</p>   </dd></dl>