QElectroTech 0.200.1-dev
Loading...
Searching...
No Matches
anonymous_namespace{logring.cpp} Namespace Reference

Functions

void writeAllSignalSafe (int fd, const char *data, int length) noexcept
 writeAllSignalSafe Loops until length bytes have been written to fd or an unrecoverable error occurs. write(2) may write fewer bytes than requested and may return EINTR – both are more likely from inside a signal handler than in normal code, so a single write() call is not enough here. Async-signal-safe: only calls write(2)/errno, nothing else.

Function Documentation

◆ writeAllSignalSafe()

void anonymous_namespace{logring.cpp}::writeAllSignalSafe ( int fd,
const char * data,
int length )
noexcept

writeAllSignalSafe Loops until length bytes have been written to fd or an unrecoverable error occurs. write(2) may write fewer bytes than requested and may return EINTR – both are more likely from inside a signal handler than in normal code, so a single write() call is not enough here. Async-signal-safe: only calls write(2)/errno, nothing else.

Here is the caller graph for this function: