windows needs timeval struct too
parent
f1205587a1
commit
7c9d7f476a
|
@ -1,8 +1,8 @@
|
|||
! Copyright (C) 2006 Mackenzie Straight, Doug Coleman.
|
||||
|
||||
! See http://factorcode.org/license.txt for BSD license.
|
||||
USING: alien alien.c-types alien.strings alien.syntax arrays
|
||||
byte-arrays kernel math sequences windows.types windows.kernel32
|
||||
windows.errors structs windows math.bitwise alias ;
|
||||
windows.errors windows math.bitwise alias ;
|
||||
IN: windows.winsock
|
||||
|
||||
USE: libc
|
||||
|
@ -138,6 +138,10 @@ C-STRUCT: addrinfo
|
|||
{ "sockaddr*" "addr" }
|
||||
{ "addrinfo*" "next" } ;
|
||||
|
||||
C-STRUCT: timeval
|
||||
{ "long" "sec" }
|
||||
{ "long" "usec" } ;
|
||||
|
||||
: hostent-addr ( hostent -- addr ) hostent-addr-list *void* ; ! *uint ;
|
||||
|
||||
LIBRARY: winsock
|
||||
|
@ -440,4 +444,3 @@ FUNCTION: void GetAcceptExSockaddrs ( void* a, int b, int c, int d, void* e, voi
|
|||
|
||||
: init-winsock ( -- )
|
||||
HEX: 0202 <wsadata> WSAStartup winsock-return-check ;
|
||||
|
||||
|
|
Loading…
Reference in New Issue