]> git.saurik.com Git - wxWidgets.git/blob - include/wx/private/socket.h
move more socket functions common to Winsock and BSD implementations to common code
[wxWidgets.git] / include / wx / private / socket.h
1 ///////////////////////////////////////////////////////////////////////////////
2 // Name: wx/private/socket.h
3 // Purpose: various wxSocket-related private declarations
4 // Author: Vadim Zeitlin
5 // Created: 2008-11-23
6 // RCS-ID: $Id$
7 // Copyright: (c) 2008 Vadim Zeitlin <vadim@wxwidgets.org>
8 // Licence: wxWindows licence
9 ///////////////////////////////////////////////////////////////////////////////
10
11 #ifndef _WX_PRIVATE_SOCKET_H_
12 #define _WX_PRIVATE_SOCKET_H_
13
14 // these definitions are for MSW when we don't use configure, otherwise these
15 // symbols are defined by configure
16 #ifndef WX_SOCKLEN_T
17 #define WX_SOCKLEN_T int
18 #endif
19
20 #ifndef SOCKOPTLEN_T
21 #define SOCKOPTLEN_T int
22 #endif
23
24 // define some symbols which winsock.h defines but traditional BSD headers
25 // don't
26 #ifndef INVALID_SOCKET
27 #define INVALID_SOCKET (-1)
28 #endif
29
30 #ifndef SOCKET_ERROR
31 #define SOCKET_ERROR (-1)
32 #endif
33
34 #if wxUSE_IPV6
35 typedef struct sockaddr_storage wxSockAddr;
36 #else
37 typedef struct sockaddr wxSockAddr;
38 #endif
39
40 #endif // _WX_PRIVATE_SOCKET_H_
41