Add set_blocking for network sockets

This commit is contained in:
Sokus
2023-03-08 13:30:12 +01:00
parent a262c0bbf3
commit 1ecab2fcbc
10 changed files with 89 additions and 0 deletions
+8
View File
@@ -190,4 +190,12 @@ Socket_Option_Error :: enum c.int {
Invalid_Option_For_Socket = c.int(os.ENOPROTOOPT),
Reset_When_Keepalive_Set = c.int(os.ENOTCONN),
Not_Socket = c.int(os.ENOTSOCK),
}
Set_Blocking_Error :: enum c.int {
None = 0,
// TODO: add errors occuring on followig calls:
// flags, _ := os.fcntl(sd, os.F_GETFL, 0)
// os.fcntl(sd, os.F_SETFL, flags | int(os.O_NONBLOCK))
}