qlibs:(timeout)

πŸ“¦
version 31 Β· 3 versions
, in alpine 3.24

🌸 NAME 🌸

okay bestie, welcome to qlibs:(timeout) β€” the manual page that's literally all about reading from and writing to a file descriptor, but with a timeout vibe check πŸ’…


πŸ“œ SYNTAX πŸ“œ

First, you gotta bring the header into the group chat:

#include "timeout.h"

Then the function signatures, exactly as they're written:

int timeoutread(int t,int fd,char *buf,int len);
int timeoutwrite(int,int,char *,int);

No cap, that second one really is written with no parameter names β€” we respect the mystery 🫢


πŸ’– DESCRIPTION πŸ’–

timeoutread reads from file descriptor fd, len bytes into buf, returning 0 on success and -1 in case a timeout has occured 😭

timeoutwrite writes to file descriptor fd, len bytes from buf, returning 0 on success and -1 in case a timeout has occured πŸ’€

That's the whole plot. Slay, honestly ✨


πŸŽ€ SEE ALSO πŸŽ€

also go see wait(3), timeoutconn(3) taia(3) β€” yes, that punctuation is exactly the vibe, iykyk 🌈


mwah πŸ’‹ signing off from page 3 of qlibs:(timeout) β€” iconic footer energy, no date in sight, and honestly? we respect it πŸ§šπŸ’œ

πŸ“¦ where this page comes from