Skip to content
Snippets Groups Projects
Commit a274a859 authored by Wesley W. Terpstra's avatar Wesley W. Terpstra
Browse files

api: unset non-blocking when requested

parent 9b424e36
Branches
Tags
No related merge requests found
......@@ -47,7 +47,7 @@ static void eb_dev_set_blocking(int fdes, int block) {
int flags;
flags = fcntl(fdes, F_GETFL, 0);
fcntl(fdes, F_SETFL, flags | (block?0:O_NONBLOCK));
fcntl(fdes, F_SETFL, (flags&~O_NONBLOCK) | (block?0:O_NONBLOCK));
}
static int eb_dev_ewouldblock() {
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment