PageRenderTime 32ms CodeModel.GetById 15ms app.highlight 12ms RepoModel.GetById 1ms app.codeStats 0ms

/std/c/freebsd/socket.d

http://github.com/jcd/phobos
D | 44 lines | 31 code | 8 blank | 5 comment | 0 complexity | 92f5905adfbd01d65f4b149cd8010ce7 MD5 | raw file
 1// Written in the D programming language.
 2
 3/*
 4 * This module is just for making std.socket work under FreeBSD, and these
 5 * definitions should actually be in druntime. (core.sys.posix.netdb or sth)
 6 */
 7module std.c.freebsd.socket;
 8
 9public import core.sys.posix.netdb;
10import core.sys.posix.sys.socket;
11
12extern(C):
13
14enum // <sys/socket.h> __BSD_VISIBLE
15{
16    AF_APPLETALK    = 16,
17    AF_IPX          = 23,
18}
19
20enum // <sys/socket.h> __BSD_VISIBLE
21{
22    SOCK_RDM        = 4,
23}
24
25enum // <sys/socket.h> __BSD_VISIBLE
26{
27    MSG_NOSIGNAL    = 0x20000,
28}
29
30enum // <netinet/in.h> __BSD_VISIBLE
31{
32    IPPROTO_IGMP    = 2,
33    IPPROTO_GGP     = 3,
34    IPPROTO_PUP     = 12,
35    IPPROTO_IDP     = 22,
36    IPPROTO_ND      = 77,
37    IPPROTO_MAX     = 256,
38}
39
40enum // <netinet/in.h>
41{
42    INADDR_LOOPBACK = 0x7f000001,
43    INADDR_NONE     = 0xffffffff,
44}