Skip to content

Instantly share code, notes, and snippets.

@fxn
Created January 13, 2012 15:09
Show Gist options
  • Save fxn/1606878 to your computer and use it in GitHub Desktop.
Save fxn/1606878 to your computer and use it in GitHub Desktop.
Traditionally, System V has returned the error EAGAIN
for a nonblocking I/O operation that cannot be satisfied,
while Berkeley-derived implementations have returned the
error EWOULDBLOCK. Because of this history, the POSIX
specification says either may be returned for this case.
Fortunately, most current systems define these two error
codes to be the same (check your system's <sys/errno.h>
header), so it doesn't matter which one we use. In this
text, we use EWOULDBLOCK.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment