diff options
author | tromey <tromey@138bc75d-0d04-0410-961f-82ee72b054a4> | 2002-08-27 16:08:31 +0000 |
---|---|---|
committer | tromey <tromey@138bc75d-0d04-0410-961f-82ee72b054a4> | 2002-08-27 16:08:31 +0000 |
commit | 1f2331f8f92ea2accadad1c9f8210580537e3cfc (patch) | |
tree | 48fd4eeb11e4db9380644fa21c9dd75585c317b8 /libjava/java/net/natPlainSocketImpl.cc | |
parent | ee5a17922a650c5bee5e390a31eda7c5f43ed237 (diff) | |
download | ppe42-gcc-1f2331f8f92ea2accadad1c9f8210580537e3cfc.tar.gz ppe42-gcc-1f2331f8f92ea2accadad1c9f8210580537e3cfc.zip |
2002-08-27 Tony Kimball <alk@pobox.com>
Tom Tromey <tromey@redhat.com>
* java/net/natPlainDatagramSocketImpl.cc (NATIVE_CLOSE): New
define.
(::close): Removed.
(PlainDatagramSocketImpl::close): Use NATIVE_CLOSE.
* java/net/natPlainSocketImpl.cc (NATIVE_CLOSE): New define.
(::close): Removed.
(PlainSocketImpl::close): Use NATIVE_CLOSE.
* include/win32.h (getcwd): Removed declaration. Include io.h.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@56605 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libjava/java/net/natPlainSocketImpl.cc')
-rw-r--r-- | libjava/java/net/natPlainSocketImpl.cc | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/libjava/java/net/natPlainSocketImpl.cc b/libjava/java/net/natPlainSocketImpl.cc index 4a75e980073..370c9946177 100644 --- a/libjava/java/net/natPlainSocketImpl.cc +++ b/libjava/java/net/natPlainSocketImpl.cc @@ -20,13 +20,9 @@ details. */ #undef MIN_PRIORITY #undef FIONREAD -// These functions make the Win32 socket API look more POSIXy -static inline int -close(int s) -{ - return closesocket(s); -} +#define NATIVE_CLOSE(s) closesocket (s) +// These functions make the Win32 socket API look more POSIXy static inline int write(int s, void *buf, int len) { @@ -63,6 +59,8 @@ read(int s, void *buf, int len) #include <errno.h> #include <string.h> +#define NATIVE_CLOSE(s) ::close (s) + #endif /* WIN32 */ #endif /* DISABLE_JAVA_NET */ @@ -429,7 +427,7 @@ java::net::PlainSocketImpl::close() JvSynchronize sync (this); // should we use shutdown here? how would that effect so_linger? - int res = ::close (fnum); + int res = NATIVE_CLOSE (fnum); if (res == -1) { |