Mon, 27 Dec 2010 03:20:35 +0000
Pre-release checklist, steps 3-6.
| 3776 | 1 | /* |
| 15884 | 2 | * purple |
|
5913
4d016c00bb36
[gaim-migrate @ 6345]
Herman Bloggs <herman@bluedigits.com>
parents:
3776
diff
changeset
|
3 | * |
|
4d016c00bb36
[gaim-migrate @ 6345]
Herman Bloggs <herman@bluedigits.com>
parents:
3776
diff
changeset
|
4 | * File: libc_internal.h |
|
4d016c00bb36
[gaim-migrate @ 6345]
Herman Bloggs <herman@bluedigits.com>
parents:
3776
diff
changeset
|
5 | * |
|
4d016c00bb36
[gaim-migrate @ 6345]
Herman Bloggs <herman@bluedigits.com>
parents:
3776
diff
changeset
|
6 | * Copyright (C) 2002-2003, Herman Bloggs <hermanator12002@yahoo.com> |
|
4d016c00bb36
[gaim-migrate @ 6345]
Herman Bloggs <herman@bluedigits.com>
parents:
3776
diff
changeset
|
7 | * |
|
4d016c00bb36
[gaim-migrate @ 6345]
Herman Bloggs <herman@bluedigits.com>
parents:
3776
diff
changeset
|
8 | * This program is free software; you can redistribute it and/or modify |
|
4d016c00bb36
[gaim-migrate @ 6345]
Herman Bloggs <herman@bluedigits.com>
parents:
3776
diff
changeset
|
9 | * it under the terms of the GNU General Public License as published by |
|
4d016c00bb36
[gaim-migrate @ 6345]
Herman Bloggs <herman@bluedigits.com>
parents:
3776
diff
changeset
|
10 | * the Free Software Foundation; either version 2 of the License, or |
|
4d016c00bb36
[gaim-migrate @ 6345]
Herman Bloggs <herman@bluedigits.com>
parents:
3776
diff
changeset
|
11 | * (at your option) any later version. |
|
4d016c00bb36
[gaim-migrate @ 6345]
Herman Bloggs <herman@bluedigits.com>
parents:
3776
diff
changeset
|
12 | * |
|
4d016c00bb36
[gaim-migrate @ 6345]
Herman Bloggs <herman@bluedigits.com>
parents:
3776
diff
changeset
|
13 | * This program is distributed in the hope that it will be useful, |
|
4d016c00bb36
[gaim-migrate @ 6345]
Herman Bloggs <herman@bluedigits.com>
parents:
3776
diff
changeset
|
14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
4d016c00bb36
[gaim-migrate @ 6345]
Herman Bloggs <herman@bluedigits.com>
parents:
3776
diff
changeset
|
15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
4d016c00bb36
[gaim-migrate @ 6345]
Herman Bloggs <herman@bluedigits.com>
parents:
3776
diff
changeset
|
16 | * GNU General Public License for more details. |
|
4d016c00bb36
[gaim-migrate @ 6345]
Herman Bloggs <herman@bluedigits.com>
parents:
3776
diff
changeset
|
17 | * |
|
4d016c00bb36
[gaim-migrate @ 6345]
Herman Bloggs <herman@bluedigits.com>
parents:
3776
diff
changeset
|
18 | * You should have received a copy of the GNU General Public License |
|
4d016c00bb36
[gaim-migrate @ 6345]
Herman Bloggs <herman@bluedigits.com>
parents:
3776
diff
changeset
|
19 | * along with this program; if not, write to the Free Software |
|
19859
71d37b57eff2
The FSF changed its address a while ago; our files were out of date.
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
15936
diff
changeset
|
20 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA |
|
5913
4d016c00bb36
[gaim-migrate @ 6345]
Herman Bloggs <herman@bluedigits.com>
parents:
3776
diff
changeset
|
21 | * |
| 3776 | 22 | */ |
| 23 | #ifndef _LIBC_INTERNAL_ | |
| 24 | #define _LIBC_INTERNAL_ | |
|
15936
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
25 | #include <glib.h> |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
26 | |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
27 | |
|
22686
d41016d7812d
Add extern "C" wrappers to win32 headers. There is also a change here that I thought I committed earlier that should provide better error messages for winsock errors.
Daniel Atallah <datallah@pidgin.im>
parents:
20239
diff
changeset
|
28 | #ifdef __cplusplus |
|
d41016d7812d
Add extern "C" wrappers to win32 headers. There is also a change here that I thought I committed earlier that should provide better error messages for winsock errors.
Daniel Atallah <datallah@pidgin.im>
parents:
20239
diff
changeset
|
29 | extern "C" { |
|
d41016d7812d
Add extern "C" wrappers to win32 headers. There is also a change here that I thought I committed earlier that should provide better error messages for winsock errors.
Daniel Atallah <datallah@pidgin.im>
parents:
20239
diff
changeset
|
30 | #endif /* __cplusplus */ |
|
d41016d7812d
Add extern "C" wrappers to win32 headers. There is also a change here that I thought I committed earlier that should provide better error messages for winsock errors.
Daniel Atallah <datallah@pidgin.im>
parents:
20239
diff
changeset
|
31 | |
|
24231
6907b62f25fe
Warnings cleanup from Lee Roach. Fixes #6242.
Daniel Atallah <datallah@pidgin.im>
parents:
22812
diff
changeset
|
32 | /* helper for purple_utf8_strftime() by way of purple_internal_strftime() in src/util.c */ |
|
6907b62f25fe
Warnings cleanup from Lee Roach. Fixes #6242.
Daniel Atallah <datallah@pidgin.im>
parents:
22812
diff
changeset
|
33 | const char *wpurple_get_timezone_abbreviation(const struct tm *tm); |
|
6907b62f25fe
Warnings cleanup from Lee Roach. Fixes #6242.
Daniel Atallah <datallah@pidgin.im>
parents:
22812
diff
changeset
|
34 | |
|
15936
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
35 | /* sys/socket.h */ |
|
22812
cf92ffc5949c
Patch from vladb to remove a C++ protected word ("namespace") from win32 libpurple code. Fixes #5471
Daniel Atallah <datallah@pidgin.im>
parents:
22686
diff
changeset
|
36 | int wpurple_socket(int domain, int style, int protocol); |
|
15936
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
37 | int wpurple_connect(int socket, struct sockaddr *addr, u_long length); |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
38 | int wpurple_getsockopt(int socket, int level, int optname, void *optval, socklen_t *optlenptr); |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
39 | int wpurple_setsockopt(int socket, int level, int optname, const void *optval, socklen_t optlen); |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
40 | int wpurple_getsockname (int socket, struct sockaddr *addr, socklen_t *lenptr); |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
41 | int wpurple_bind(int socket, struct sockaddr *addr, socklen_t length); |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
42 | int wpurple_listen(int socket, unsigned int n); |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
43 | int wpurple_sendto(int socket, const void *buf, size_t len, int flags, const struct sockaddr *to, socklen_t tolen); |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
44 | int wpurple_recv(int fd, void *buf, size_t len, int flags); |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
45 | int wpurple_send(int fd, const void *buf, unsigned int size, int flags); |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
46 | |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
47 | /* arpa/inet.h */ |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
48 | int wpurple_inet_aton(const char *name, struct in_addr *addr); |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
49 | const char * |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
50 | wpurple_inet_ntop (int af, const void *src, char *dst, socklen_t cnt); |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
51 | |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
52 | /* netdb.h */ |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
53 | struct hostent* wpurple_gethostbyname(const char *name); |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
54 | |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
55 | /* string.h */ |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
56 | char* wpurple_strerror( int errornum ); |
| 3776 | 57 | |
| 58 | /* fcntl.h */ | |
|
20239
ae122f419324
applied changes from 2762c6075c0dc52a96098c5478c5bf68cfd890a3
Luke Schierer <lschiere@pidgin.im>
parents:
19859
diff
changeset
|
59 | int wpurple_fcntl(int socket, int command, ...); |
|
ae122f419324
applied changes from 2762c6075c0dc52a96098c5478c5bf68cfd890a3
Luke Schierer <lschiere@pidgin.im>
parents:
19859
diff
changeset
|
60 | #define F_GETFL 3 |
|
ae122f419324
applied changes from 2762c6075c0dc52a96098c5478c5bf68cfd890a3
Luke Schierer <lschiere@pidgin.im>
parents:
19859
diff
changeset
|
61 | #define F_SETFL 4 |
|
ae122f419324
applied changes from 2762c6075c0dc52a96098c5478c5bf68cfd890a3
Luke Schierer <lschiere@pidgin.im>
parents:
19859
diff
changeset
|
62 | #define O_NONBLOCK 04000 |
| 3776 | 63 | |
|
15936
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
64 | /* sys/ioctl.h */ |
|
11364
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
65 | #define SIOCGIFCONF 0x8912 /* get iface list */ |
|
15936
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
66 | int wpurple_ioctl(int fd, int command, void* opt); |
|
11364
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
67 | |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
68 | /* net/if.h */ |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
69 | struct ifreq |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
70 | { |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
71 | union |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
72 | { |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
73 | char ifrn_name[6]; /* Interface name, e.g. "en0". */ |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
74 | } ifr_ifrn; |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
75 | |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
76 | union |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
77 | { |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
78 | struct sockaddr ifru_addr; |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
79 | #if 0 |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
80 | struct sockaddr ifru_dstaddr; |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
81 | struct sockaddr ifru_broadaddr; |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
82 | struct sockaddr ifru_netmask; |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
83 | struct sockaddr ifru_hwaddr; |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
84 | short int ifru_flags; |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
85 | int ifru_ivalue; |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
86 | int ifru_mtu; |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
87 | #endif |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
88 | char *ifru_data; |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
89 | } ifr_ifru; |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
90 | }; |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
91 | # define ifr_name ifr_ifrn.ifrn_name /* interface name */ |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
92 | # define ifr_addr ifr_ifru.ifru_addr /* address */ |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
93 | #if 0 |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
94 | # define ifr_hwaddr ifr_ifru.ifru_hwaddr /* MAC address */ |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
95 | # define ifr_dstaddr ifr_ifru.ifru_dstaddr /* other end of p-p lnk */ |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
96 | # define ifr_broadaddr ifr_ifru.ifru_broadaddr /* broadcast address */ |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
97 | # define ifr_netmask ifr_ifru.ifru_netmask /* interface net mask */ |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
98 | # define ifr_flags ifr_ifru.ifru_flags /* flags */ |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
99 | # define ifr_metric ifr_ifru.ifru_ivalue /* metric */ |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
100 | # define ifr_mtu ifr_ifru.ifru_mtu /* mtu */ |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
101 | #endif |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
102 | # define ifr_data ifr_ifru.ifru_data /* for use by interface */ |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
103 | #if 0 |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
104 | # define ifr_ifindex ifr_ifru.ifru_ivalue /* interface index */ |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
105 | # define ifr_bandwidth ifr_ifru.ifru_ivalue /* link bandwidth */ |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
106 | # define ifr_qlen ifr_ifru.ifru_ivalue /* queue length */ |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
107 | #endif |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
108 | |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
109 | |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
110 | struct ifconf |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
111 | { |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
112 | int ifc_len; /* Size of buffer. */ |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
113 | union |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
114 | { |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
115 | char *ifcu_buf; |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
116 | struct ifreq *ifcu_req; |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
117 | } ifc_ifcu; |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
118 | }; |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
119 | # define ifc_buf ifc_ifcu.ifcu_buf /* Buffer address. */ |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
120 | # define ifc_req ifc_ifcu.ifcu_req /* Array of structures. */ |
|
d754cf40ec4b
[gaim-migrate @ 13588]
Daniel Atallah <datallah@pidgin.im>
parents:
5913
diff
changeset
|
121 | |
| 3776 | 122 | /* sys/time.h */ |
|
27854
77d4e2090a5d
Use mingw's <sys/time.h> to define "struct timezone" when it is new enough.
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
24231
diff
changeset
|
123 | #if __MINGW32_MAJOR_VERSION < 3 || (__MINGW32_MAJOR_VERSION == 3 && __MINGW32_MINOR_VERSION < 10) |
| 3776 | 124 | struct timezone { |
| 125 | int tz_minuteswest; | |
| 126 | int tz_dsttime; | |
| 127 | }; | |
|
27854
77d4e2090a5d
Use mingw's <sys/time.h> to define "struct timezone" when it is new enough.
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
24231
diff
changeset
|
128 | #else |
|
77d4e2090a5d
Use mingw's <sys/time.h> to define "struct timezone" when it is new enough.
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
24231
diff
changeset
|
129 | # include <sys/time.h> |
|
77d4e2090a5d
Use mingw's <sys/time.h> to define "struct timezone" when it is new enough.
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
24231
diff
changeset
|
130 | #endif |
|
15936
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
131 | int wpurple_gettimeofday(struct timeval *p, struct timezone *z); |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
132 | |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
133 | /* time.h */ |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
134 | struct tm *wpurple_localtime_r(const time_t *time, struct tm *resultp); |
| 3776 | 135 | |
| 136 | ||
|
15936
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
137 | /* unistd.h */ |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
138 | int wpurple_read(int fd, void *buf, unsigned int size); |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
139 | int wpurple_write(int fd, const void *buf, unsigned int size); |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
140 | int wpurple_close(int fd); |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
141 | int wpurple_gethostname(char *name, size_t size); |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
142 | |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
143 | |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
144 | /* stdio.h */ |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
145 | int wpurple_rename(const char *oldname, const char *newname); |
|
1a5a326484f3
move internal stuff to libc_internal.h to fix warnings
Daniel Atallah <datallah@pidgin.im>
parents:
15884
diff
changeset
|
146 | |
|
22686
d41016d7812d
Add extern "C" wrappers to win32 headers. There is also a change here that I thought I committed earlier that should provide better error messages for winsock errors.
Daniel Atallah <datallah@pidgin.im>
parents:
20239
diff
changeset
|
147 | #ifdef __cplusplus |
|
d41016d7812d
Add extern "C" wrappers to win32 headers. There is also a change here that I thought I committed earlier that should provide better error messages for winsock errors.
Daniel Atallah <datallah@pidgin.im>
parents:
20239
diff
changeset
|
148 | } |
|
d41016d7812d
Add extern "C" wrappers to win32 headers. There is also a change here that I thought I committed earlier that should provide better error messages for winsock errors.
Daniel Atallah <datallah@pidgin.im>
parents:
20239
diff
changeset
|
149 | #endif /* __cplusplus */ |
|
d41016d7812d
Add extern "C" wrappers to win32 headers. There is also a change here that I thought I committed earlier that should provide better error messages for winsock errors.
Daniel Atallah <datallah@pidgin.im>
parents:
20239
diff
changeset
|
150 | |
| 3776 | 151 | #endif /* _LIBC_INTERNAL_ */ |