nanomsg next generation NNG  
Home GitHub Documentation

This documentation is for version v1.2.2 of nng, but the latest released version is v1.7.3. see the documentation for v1.7.3 for the most up-to-date information.
nng_stream_listener_accept(3str)

SYNOPSIS

#include <nng/nng.h>

void nng_stream_listener_accept(nng_stream_listener *l, nng_aio *aio);

DESCRIPTION

The nng_stream_listener_accept() attempts to accept an incoming byte stream connection from a remote peer, using the listener l. The operation is completed asynchronously, using aio.

This operation can only be done after the listener is already listening.

If a connection is successfully established, the aio will have the resulting nng_stream object stored as its first output, which can be retrieved with nng_aio_get_output().

RETURN VALUES

None.

ERRORS

NNG_ECANCELED

The operation was aborted.

NNG_ECLOSED

The listener is closed.

NNG_ECONNRESET

The connection was reset by the peer.

NNG_ENOMEM

Insufficient free memory exists.

NNG_ESTATE

The listener is not not listening.

NNG Reference Manual vv1.2.2 © 2019 Staysail Systems, Inc, © 2018 Capitar IT Group BV
This document is supplied under the MIT License.
nanomsg™ and nng™ are trademarks of Garrett D'Amore.