libssh2\_channel\_forward\_accept(3) libssh2 libssh2\_channel\_forward\_accept(3)

# [NAME](#NAME)

libssh2\_channel\_forward\_accept - accept a queued connection

# [SYNOPSIS](#SYNOPSIS)

```
#include <libssh2.h>
LIBSSH2_CHANNEL *
libssh2_channel_forward_accept(LIBSSH2_LISTENER *listener);
```

# [DESCRIPTION](#DESCRIPTION)

*listener* is a forwarding listener instance as returned by [**libssh2\_channel\_forward\_listen\_ex(3)**](/man/os/libssh2/libssh2_channel_forward_listen_ex.3).

# [RETURN VALUE](#RETURN_VALUE)

A newly allocated channel instance or NULL on failure.

# [ERRORS](#ERRORS)

When this function returns NULL use [*libssh2\_session\_last\_errno(3)*](/man/os/libssh2/libssh2_session_last_errno.3) to extract the error code. If that code is *LIBSSH2\_ERROR\_EAGAIN*, the session is set to do non-blocking I/O but the call would block.

# [SEE ALSO](#SEE_ALSO)

[**libssh2\_channel\_forward\_listen\_ex(3)**](/man/os/libssh2/libssh2_channel_forward_listen_ex.3)

1 Jun 2007 libssh2 0.15

---

Document: libssh2_channel_forward_accept(3) from libssh2 1.11.1-r11 (Chainguard OS)
Source: https://github.com/libssh2/libssh2.git
