diff options
Diffstat (limited to 'ref/api')
| -rw-r--r-- | ref/api/aio.html | 2 | ||||
| -rw-r--r-- | ref/api/ctx.html | 2 | ||||
| -rw-r--r-- | ref/api/init.html | 2 | ||||
| -rw-r--r-- | ref/api/misc.html | 16 |
4 files changed, 11 insertions, 11 deletions
diff --git a/ref/api/aio.html b/ref/api/aio.html index 1ce6258e..897629df 100644 --- a/ref/api/aio.html +++ b/ref/api/aio.html @@ -255,7 +255,7 @@ operations that are already in progress as well setting a maximum <p>It is also possible to initiate an asynchronous operation, and <a href="/api/aio.html#wait-for-completion">wait</a> for it to complete, creating a synchronous flow from an asynchronous one.</p> <h2 id="create-handle"><a class="header" href="#create-handle">Create Handle</a></h2> -<pre><code class="language-c">int nng_aio_alloc(nng_aio **aiop, void (*callb)(void *), void *arg); +<pre><code class="language-c">nng_err nng_aio_alloc(nng_aio **aiop, void (*callb)(void *), void *arg); </code></pre> <p>The <a name="a004"></a><code>nng_aio_alloc</code> function creates an <a href="/api/aio.html#asynchronous-io-handle"><code>nng_aio</code></a> object, with the <a name="a005"></a>callback <em>callb</em> taking the argument <em>arg</em>, and returns it in <em>aiop</em>.</p> diff --git a/ref/api/ctx.html b/ref/api/ctx.html index c0082b33..2b8c2cab 100644 --- a/ref/api/ctx.html +++ b/ref/api/ctx.html @@ -286,7 +286,7 @@ call is executed may also return with an <code>NNG_ECLOSED</code> result.</p> <span class="mdbook-alerts-icon"></span> note </p> -<p>Closing the socket associated with <em>ctx</em> using <code>nng_socket_close</code>] also closes this context.</p> +<p>Closing the socket associated with <em>ctx</em> using <a href="/api/sock.html#closing-a-socket"><code>nng_socket_close</code></a> also closes this context.</p> </div> <h2 id="sending-messages"><a class="header" href="#sending-messages">Sending Messages</a></h2> <pre><code class="language-c">int nng_ctx_sendmsg(nng_ctx ctx, nng_msg *msg, int flags); diff --git a/ref/api/init.html b/ref/api/init.html index 807c6669..e4a759da 100644 --- a/ref/api/init.html +++ b/ref/api/init.html @@ -235,7 +235,7 @@ finalize the library and deallocate any resources used by the library.</p> int16_t num_resolver_threads; } nng_init_params; -extern int nng_init(nng_init_parms *params); +extern nng_err nng_init(nng_init_parms *params); </code></pre> <p>Before using other interfaces in this library, it is necessary to initialize the library. The <a name="a001"></a><code>nng_init</code> function performs this initialization.</p> diff --git a/ref/api/misc.html b/ref/api/misc.html index 2c1aea8f..18e7dc58 100644 --- a/ref/api/misc.html +++ b/ref/api/misc.html @@ -231,13 +231,13 @@ The value returned is suitable for use with cryptographic functions such as key generation, and is obtained using platform-specific cryptographically strong random number facilities when available.</p> <h2 id="create-socket-pair"><a class="header" href="#create-socket-pair">Create Socket Pair</a></h2> -<pre><code class="language-c">int nng_socket_pair(int fds[2]); +<pre><code class="language-c">nng_err nng_socket_pair(int fds[2]); </code></pre> -<p>The <code>nng_socket_pair</code> function creates a pair of connected file descriptors. +<p>The <a name="a003"></a><code>nng_socket_pair</code> function creates a pair of connected file descriptors. These file descriptors, which are returned in the <em>fds</em> array, are suitable for use with the <a href="/tran/socket.html">Socket transport</a>.</p> <p>On POSIX platforms, this is a thin wrapper around the standard <code>socketpair</code> function, -using the <a name="a003"></a><code>AF_UNIX</code> family and the <code>SOCK_STREAM</code> socket type. +using the <a name="a004"></a><code>AF_UNIX</code> family and the <code>SOCK_STREAM</code> socket type. <sup><a name="to-footnote-1"><a href="#footnote-1">1</a></a></sup></p> <p>This will return zero on success, or an error number. On platforms that lack this capability, such as Windows, it will return <code>NNG_ENOTSUP</code>.</p> @@ -252,19 +252,19 @@ a child process on UNIX platforms, without requiring the processes use a shared <h2 id="report-library-version"><a class="header" href="#report-library-version">Report Library Version</a></h2> <pre><code class="language-c">const char * nng_version(void); </code></pre> -<p>The <a name="a004"></a><code>nng_version</code> function returns a human readable <a name="a005"></a>version number +<p>The <a name="a005"></a><code>nng_version</code> function returns a human readable <a name="a006"></a>version number for <em>NNG</em>, formatted as a <code>NUL</code>-terminated string.</p> <p>Additionally, compile time version information is available via some predefined macros:</p> <ul> -<li><a name="a006"></a><code>NNG_MAJOR_VERSION</code>: Major version number.</li> -<li><a name="a007"></a><code>NNG_MINOR_VERSION</code>: Minor version number.</li> -<li><a name="a008"></a><code>NNG_PATCH_VERSION</code>: Patch version number.</li> +<li><a name="a007"></a><code>NNG_MAJOR_VERSION</code>: Major version number.</li> +<li><a name="a008"></a><code>NNG_MINOR_VERSION</code>: Minor version number.</li> +<li><a name="a009"></a><code>NNG_PATCH_VERSION</code>: Patch version number.</li> </ul> <p><em>NNG</em> is developed and released using <a href="http://www.semver.org">Semantic Versioning 2.0</a>, and the version numbers reported refer to both the API and the library itself. -(The <a name="a009"></a>ABI – <a name="a010"></a>application binary interface – between the +(The <a name="a010"></a>ABI – <a name="a011"></a>application binary interface – between the library and the application is controlled in a similar, but different manner depending upon the link options and how the library is built.)</p> <!-- Symbol cross reference --> |
