std1.0.0-beta-7 SafeC docs

std :: sched::io_nb

Function std::tcp_wait_connected

#include <std/sched/io_nb.h> source ยท definition

int tcp_wait_connected(int fd)

Blocks until a tcp_connect_nb socket's handshake finishes (poll for writable, then SO_ERROR), with no time limit of its own. Returns 0 if connected, -1 if the connect failed (refused, unreachable, ...). For synchronous callers; a std::Reactor task awaits SCHED_WRITE instead.