diff options
| author | gdamore <gdamore@users.noreply.github.com> | 2025-01-15 15:03:06 +0000 |
|---|---|---|
| committer | gdamore <gdamore@users.noreply.github.com> | 2025-01-15 15:03:06 +0000 |
| commit | e605ded920a4636e93edbbea31d9625ca5428dfb (patch) | |
| tree | 32c6bbde7db2e643f56aa60e94ececcb6dee6b10 /ref/api/misc.html | |
| parent | 2b8d71694ea8755881bdb8d8fe1fdcc9d4055eac (diff) | |
| download | nng-e605ded920a4636e93edbbea31d9625ca5428dfb.tar.gz nng-e605ded920a4636e93edbbea31d9625ca5428dfb.tar.bz2 nng-e605ded920a4636e93edbbea31d9625ca5428dfb.zip | |
deploy: cd9901549239bbe424bc70a48b09f33064d906b6
Diffstat (limited to 'ref/api/misc.html')
| -rw-r--r-- | ref/api/misc.html | 16 |
1 files changed, 8 insertions, 8 deletions
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 --> |
