2 Unix SMB/CIFS implementation.
4 networking system include wrappers
6 Copyright (C) Andrew Tridgell 2004
8 This program is free software; you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation; either version 2 of the License, or
11 (at your option) any later version.
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
18 You should have received a copy of the GNU General Public License
19 along with this program; if not, write to the Free Software
20 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
23 #ifdef HAVE_SYS_SOCKET_H
24 #include <sys/socket.h>
27 #ifdef HAVE_UNIXSOCKET
31 #include <netinet/in.h>
32 #include <arpa/inet.h>
35 #ifdef HAVE_NETINET_TCP_H
36 #include <netinet/tcp.h>
40 * The next three defines are needed to access the IPTOS_* options
44 #ifdef HAVE_NETINET_IN_SYSTM_H
45 #include <netinet/in_systm.h>
48 #ifdef HAVE_NETINET_IN_IP_H
49 #include <netinet/in_ip.h>
52 #ifdef HAVE_NETINET_IP_H
53 #include <netinet/ip.h>
61 #ifdef REPLACE_INET_NTOA
62 #define inet_ntoa rep_inet_ntoa
66 * glibc on linux doesn't seem to have MSG_WAITALL
67 * defined. I think the kernel has it though..
74 * Some older systems seem not to have MAXHOSTNAMELEN
77 #ifndef MAXHOSTNAMELEN
78 #define MAXHOSTNAMELEN 254
81 #ifndef HAVE_SOCKLEN_T_TYPE
82 typedef int socklen_t;