CommandRuntime.ready_fd
Readable exactly when wait_ready() would return without blocking, for a caller that owns an event loop and cannot park a thread in wait_ready().
Source and package
- Qualified name
-
libtmux::Command Runtime:: ready _fd - Namespace
- libtmux
- Declared in
CommandRuntime- Package
- libtmux-cxx
- Source
- include/libtmux/async.hpp
-
Description#
The same contract as
Connection::notification_fd():Readability is the signal. Do not read from it: the byte carries nothing and is this runtime's to consume. Drain by taking the work —
dispatch_ready()ordiscard_ready()— which clears it.A closed runtime makes it readable, so a poller learns that no answer is coming rather than waiting for one.
Valid until this runtime is destroyed or moved from.
-1when the pipe could not be created, and on Windows, where the runtime has no descriptor to offer; a caller that gets-1useswait_ready().