diff options
Diffstat (limited to 'libjava/include/posix.h')
-rw-r--r-- | libjava/include/posix.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/libjava/include/posix.h b/libjava/include/posix.h index 0e1220a..0aadd47 100644 --- a/libjava/include/posix.h +++ b/libjava/include/posix.h @@ -60,6 +60,8 @@ _Jv_platform_close_on_exec (jint fd) ::fcntl (fd, F_SETFD, FD_CLOEXEC); } +#undef fcntl + #ifdef JV_HASH_SYNCHRONIZATION inline void _Jv_platform_usleep (unsigned long usecs) @@ -80,18 +82,24 @@ _Jv_socket (int domain, int type, int protocol) return ::socket (domain, type, protocol); } +#undef socket + inline int _Jv_connect (jint fd, sockaddr *ptr, int len) { return ::connect (fd, ptr, len); } +#undef connect + inline int _Jv_close (jint fd) { return ::close (fd); } +#undef close + // Avoid macro definitions of bind from system headers, e.g. on // Solaris 7 with _XOPEN_SOURCE. FIXME inline int @@ -100,6 +108,8 @@ _Jv_bind (int fd, struct sockaddr *addr, int addrlen) return ::bind (fd, addr, addrlen); } +#undef bind + // Same problem with accept on Tru64 UNIX with _POSIX_PII_SOCKET inline int _Jv_accept (int fd, struct sockaddr *addr, socklen_t *addrlen) @@ -107,24 +117,32 @@ _Jv_accept (int fd, struct sockaddr *addr, socklen_t *addrlen) return ::accept (fd, addr, addrlen); } +#undef accept + inline int _Jv_listen (int fd, int backlog) { return ::listen (fd, backlog); } +#undef listen + inline int _Jv_write(int s, void *buf, int len) { return ::write (s, buf, len); } +#undef write + inline int _Jv_read(int s, void *buf, int len) { return ::read (s, buf, len); } +#undef read + #endif /* DISABLE_JAVA_NET */ #endif /* __JV_POSIX_H__ */ |