libssh2_channel_wait_closed(3)
π libssh2_channel_wait_closed(3) π
okay bestie, welcome to the libssh2 manual, and today's main character is libssh2_channel_wait_closed β literally the "bestie hold on, they're still typing" function π«Ά
β¨ NAME β¨
libssh2_channel_wait_closed β wait for the remote to close the channel π
πΈ SYNOPSIS πΈ
#include <libssh2.h>
int
libssh2_channel_wait_closed(LIBSSH2_CHANNEL *channel);
π¦ DESCRIPTION π¦
So here's the vibe: you call this and you enter a temporary blocking state until the remote host closes the named channel. That's it, that's the whole personality β¨
It's typically sent after libssh2_channel_close(3), and the whole point of sitting there waiting is so you can go examine the exit status. Like, you can't read the receipt until the store actually closes, yk? π
π RETURN VALUE π
- Returns
0on success, or negative on failure. no cap. - It returns
LIBSSH2_ERROR_EAGAINwhen it would otherwise block. - And like, yes,
LIBSSH2_ERROR_EAGAINis a negative number, but bestie, it is not really a failure per se. don't panic. it's giving "try again later", not "everything is on fire" π
π SEE ALSO π
and that's the page fr fr π this one's from libssh2 version 0.19, dated 29 Nov 2007 β yeah she's vintage, she's iconic, she ate πππ¦
π¦ where this page comes from
- alpine 3.22: libssh2-doc 1.11.1-r3 Β· BSD-3-Clause
- alpine 3.23: libssh2-doc 1.11.1-r4 Β· BSD-3-Clause
- alpine 3.24: libssh2-doc 1.11.1-r4 Β· BSD-3-Clause
- arch rolling: libssh2 1.11.1-7 Β· BSD-3-Clause
- debian trixie: libssh2-1-dev 1.11.1-1+deb13u1 Β· BSD3
- debian trixie: libssh2-1-dev 1.11.1-1+deb13u2 Β· BSD3
- epel 10: libssh2-docs 1.11.1-9.el10_3 Β· BSD-3-Clause
- epel 9: libssh2-docs 1.11.1-9.el9 Β· BSD-3-Clause
- fedora 43: libssh2-docs 1.11.1-4.fc43 Β· BSD-3-Clause
- fedora 43: libssh2-docs 1.11.1-9.fc43 Β· BSD-3-Clause
- fedora 44: libssh2-docs 1.11.1-5.fc44 Β· BSD-3-Clause
- fedora 44: libssh2-docs 1.11.1-9.fc44 Β· BSD-3-Clause
- opensuse-leap 16.0: libssh2-devel 1.11.1-160000.5.1 Β· BSD-3-Clause
- opensuse-leap 16.0: libssh2-devel 1.11.1-160000.5.1 Β· BSD-3-Clause
- opensuse-leap 16.0: libssh2-devel 1.11.1-160000.5.1 Β· BSD-3-Clause
- opensuse-leap 16.0: libssh2-devel 1.11.1-160000.5.1 Β· BSD-3-Clause
- ubuntu questing: libssh2-1-dev 1.11.1-1build1
- ubuntu questing: libssh2-1-dev 1.11.1-1ubuntu0.25.10.2
- ubuntu resolute: libssh2-1-dev 1.11.1-1build2 Β· BSD3
- ubuntu resolute: libssh2-1-dev 1.11.1-1ubuntu0.26.04.4 Β· BSD3
- ubuntu stonking: libssh2-1-dev 1.11.1-6 Β· BSD3
- π the page's license: BSD-3-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms