logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

io_tryreadtimeout - read from a descriptor without blocking

Description

       io_tryreadtimeout is identical to io_tryread, with the following exception: if

       •  io_tryread returns -1 (the descriptor is not ready for reading), and

       •  the descriptor has a timeout, and

       •  the read attempt was after the descriptor's timeout,

       then io_tryreadtimeout instead returns -2, with errno set to ETIMEDOUT.

Name

       io_tryreadtimeout - read from a descriptor without blocking

See Also

io_nonblock(3), io_waitread(3), io_tryread(3)

                                                                                            io_tryreadtimeout(3)

Syntax

#include<libowfat/io.h>

       int io_tryreadtimeout(int64 fd,char* buf,int64 len);

See Also