mirror of
https://github.com/Ed94/Odin.git
synced 2026-06-24 06:35:00 -07:00
Add socket() function to windows ws32 bindings
It looks like this was missing from the winsock bindings. Odin contains WSASocketW which I assume would also work for obtaining a socket, but socket() is distinct and is what I was using, so I assume others will want it too.
This commit is contained in:
@@ -39,6 +39,11 @@ foreign ws2_32 {
|
||||
g: GROUP,
|
||||
dwFlags: DWORD,
|
||||
) -> SOCKET ---
|
||||
socket :: proc(
|
||||
af: c_int,
|
||||
type: c_int,
|
||||
protocol: c_int,
|
||||
) -> SOCKET ---
|
||||
|
||||
ioctlsocket :: proc(s: SOCKET, cmd: c_long, argp: ^c_ulong) -> c_int ---
|
||||
closesocket :: proc(socket: SOCKET) -> c_int ---
|
||||
|
||||
Reference in New Issue
Block a user