mirror of
https://github.com/c3lang/c3c.git
synced 2026-02-27 12:01:16 +00:00
cross platform socket interface (#857)
* lib/std/net: add Network, Socket and Listener Signed-off-by: Pierre Curto <pierre.curto@gmail.com> * lib/std/net: add SocketOption Signed-off-by: Pierre Curto <pierre.curto@gmail.com> * lib/std/net: fixes for win32 and wasm Signed-off-by: Pierre Curto <pierre.curto@gmail.com> --------- Signed-off-by: Pierre Curto <pierre.curto@gmail.com>
This commit is contained in:
@@ -9,4 +9,11 @@ const int PLATFORM_AF_BRIDGE = 7;
|
||||
const int PLATFORM_AF_AAL5 = 8;
|
||||
const int PLATFORM_AF_X25 = 9;
|
||||
|
||||
const PLATFORM_O_NONBLOCK = 0o4000;
|
||||
const PLATFORM_O_NONBLOCK = 0o4000;
|
||||
|
||||
// https://git.sr.ht/~sircmpwn/hare/tree/master/item/rt/+linux/socket.ha
|
||||
const int SOL_SOCKET = 1;
|
||||
const int SO_REUSEADDR = 2;
|
||||
const int SO_BROADCAST = 6;
|
||||
const int SO_KEEPALIVE = 9;
|
||||
const int SO_REUSEPORT = 15;
|
||||
Reference in New Issue
Block a user