- more fixes for inet_* with vc9/xp

This commit is contained in:
Pierre Joye 2008-08-23 20:31:27 +00:00
parent 1c4853d826
commit 7700551e7a
3 changed files with 6 additions and 1 deletions

View file

@ -163,6 +163,7 @@ PHPAPI int php_flock(int fd, int operation)
} }
#endif #endif
#ifndef PHP_WIN32
#if !(HAVE_INET_ATON) #if !(HAVE_INET_ATON)
/* {{{ inet_aton /* {{{ inet_aton
* Check whether "cp" is a valid ascii representation * Check whether "cp" is a valid ascii representation
@ -226,7 +227,7 @@ int inet_aton(const char *cp, struct in_addr *ap)
} }
/* }}} */ /* }}} */
#endif /* !HAVE_INET_ATON */ #endif /* !HAVE_INET_ATON */
#endif /* !PHP_WIN32 */
/* /*
* Local variables: * Local variables:
* tab-width: 4 * tab-width: 4

View file

@ -49,7 +49,9 @@ PHPAPI int flock(int fd, int operation);
#include <arpa/inet.h> #include <arpa/inet.h>
#endif #endif
#ifndef PHP_WIN32
extern int inet_aton(const char *, struct in_addr *); extern int inet_aton(const char *, struct in_addr *);
#endif #endif
#endif
#endif /* FLOCK_COMPAT_H */ #endif /* FLOCK_COMPAT_H */

View file

@ -1,7 +1,9 @@
#include "config.w32.h"
#if _MSC_VER >= 1500 #if _MSC_VER >= 1500
# include <In6addr.h> # include <In6addr.h>
#endif #endif
#include <Ws2tcpip.h> #include <Ws2tcpip.h>
#if (_WIN32_WINNT < 0x0600) /* Vita/2k8 have these functions */ #if (_WIN32_WINNT < 0x0600) /* Vita/2k8 have these functions */
PHPAPI int inet_pton(int af, const char* src, void* dst); PHPAPI int inet_pton(int af, const char* src, void* dst);
PHPAPI const char* inet_ntop(int af, const void* src, char* dst, size_t size); PHPAPI const char* inet_ntop(int af, const void* src, char* dst, size_t size);