ObjFW  Diff

Differences From Artifact [5394fb29aa]:

To Artifact [ccaba69181]:


44
45
46
47
48
49
50
51




52
53
54
55
56

57

58
59
60
61
62
63
64













65
66
67
68
69
70
71
# define SOMAXCONN 16
#endif

#ifndef SOCK_CLOEXEC
# define SOCK_CLOEXEC 0
#endif

#if defined(OF_MORPHOS)




# include <sys/filio.h>
# define closesocket(sock) CloseSocket(sock)
# define ioctlsocket(fd, req, arg) IoctlSocket(fd, req, arg)
# define hstrerror(err) "unknown (no hstrerror)"
# define SOCKET_ERROR -1

typedef uint32_t in_addr_t;

#elif !defined(OF_WINDOWS) && !defined(OF_WII)
# define closesocket(sock) close(sock)
#endif

#ifdef OF_MORPHOS_IXEMUL
typedef uint32_t in_addr_t;
#endif














#ifdef OF_WII
# define accept(sock, addr, addrlen) net_accept(sock, addr, addrlen)
# define bind(sock, addr, addrlen) net_bind(sock, addr, addrlen)
# define closesocket(sock) net_close(sock)
# define connect(sock, addr, addrlen) \
    net_connect(sock, (struct sockaddr *)addr, addrlen)







|
>
>
>
>





>

>







>
>
>
>
>
>
>
>
>
>
>
>
>







44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
# define SOMAXCONN 16
#endif

#ifndef SOCK_CLOEXEC
# define SOCK_CLOEXEC 0
#endif

#if defined(OF_AMIGAOS)
# ifdef OF_AMIGAOS4
#  define __USE_INLINE__
# endif
# include <proto/bsdsocket.h>
# include <sys/filio.h>
# define closesocket(sock) CloseSocket(sock)
# define ioctlsocket(fd, req, arg) IoctlSocket(fd, req, arg)
# define hstrerror(err) "unknown (no hstrerror)"
# define SOCKET_ERROR -1
# ifdef OF_MORPHOS
typedef uint32_t in_addr_t;
# endif
#elif !defined(OF_WINDOWS) && !defined(OF_WII)
# define closesocket(sock) close(sock)
#endif

#ifdef OF_MORPHOS_IXEMUL
typedef uint32_t in_addr_t;
#endif

#if defined(OF_AMIGAOS_M68K)
# define select(nfds, readfds, writefds, errorfds, timeout) \
    WaitSelect(nfds, readfds, writefds, errorfds, (struct __timeval *)timeout, \
    NULL)
#elif defined(OF_AMIGAOS4)
# define select(nfds, readfds, writefds, errorfds, timeout) \
    WaitSelect(nfds, readfds, writefds, errorfds, (struct TimeVal *)timeout, \
    NULL)
#elif defined(OF_MORPHOS)
# define select(nfds, readfds, writefds, errorfds, timeout) \
    WaitSelect(nfds, readfds, writefds, errorfds, timeout, NULL)
#endif

#ifdef OF_WII
# define accept(sock, addr, addrlen) net_accept(sock, addr, addrlen)
# define bind(sock, addr, addrlen) net_bind(sock, addr, addrlen)
# define closesocket(sock) net_close(sock)
# define connect(sock, addr, addrlen) \
    net_connect(sock, (struct sockaddr *)addr, addrlen)