aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBryce McKinlay <bryce@waitaki.otago.ac.nz>2002-03-11 04:15:51 +0000
committerBryce McKinlay <bryce@gcc.gnu.org>2002-03-11 04:15:51 +0000
commit60678e476f75be5618f87e9cd11cf25f0fac29ac (patch)
tree938d65b442fa85aed376d832f42e0dff2631f9d8
parent72da3c3e58feecb1579bf060c92f574b1bb66ed0 (diff)
downloadgcc-60678e476f75be5618f87e9cd11cf25f0fac29ac.zip
gcc-60678e476f75be5618f87e9cd11cf25f0fac29ac.tar.gz
gcc-60678e476f75be5618f87e9cd11cf25f0fac29ac.tar.bz2
posix.h: Add multiple include header protection.
* include/posix.h: Add multiple include header protection. * java/net/natPlainSocketImpl.cc: Don't #include <posix.h>. From-SVN: r50559
-rw-r--r--libjava/ChangeLog5
-rw-r--r--libjava/include/posix.h5
-rw-r--r--libjava/java/net/natPlainSocketImpl.cc1
3 files changed, 10 insertions, 1 deletions
diff --git a/libjava/ChangeLog b/libjava/ChangeLog
index 80f2eda..3554f1a 100644
--- a/libjava/ChangeLog
+++ b/libjava/ChangeLog
@@ -1,3 +1,8 @@
+2002-03-10 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
+
+ * include/posix.h: Add multiple include header protection.
+ * java/net/natPlainSocketImpl.cc: Don't #include <posix.h>.
+
2002-03-10 Adam Megacz <adam@xwt.org>
* java/net/natPlainSocketImpl.cc: Added #include <platform.h>.
diff --git a/libjava/include/posix.h b/libjava/include/posix.h
index 05c6ddf..7e9aaf5 100644
--- a/libjava/include/posix.h
+++ b/libjava/include/posix.h
@@ -8,6 +8,9 @@ This software is copyrighted work licensed under the terms of the
Libgcj License. Please consult the file "LIBGCJ_LICENSE" for
details. */
+#ifndef __JV_POSIX_H__
+#define __JV_POSIX_H__
+
/* Required on Tru64 UNIX V4/V5 so <sys/socket.h> defines prototypes of
socket functions with socklen_t instead of size_t. This must be defined
early so <standards.h> defines the correct version of __PIIX. */
@@ -42,3 +45,5 @@ _Jv_platform_close_on_exec (jint fd)
// Ignore errors.
fcntl (fd, F_SETFD, FD_CLOEXEC);
}
+
+#endif
diff --git a/libjava/java/net/natPlainSocketImpl.cc b/libjava/java/net/natPlainSocketImpl.cc
index 8559651..aecbd4e 100644
--- a/libjava/java/net/natPlainSocketImpl.cc
+++ b/libjava/java/net/natPlainSocketImpl.cc
@@ -45,7 +45,6 @@ read(int s, void *buf, int len)
#define ENOPROTOOPT 109
#endif
#else /* WIN32 */
-#include "posix.h"
#include <sys/socket.h>
#include <netinet/in.h>
#include <netinet/tcp.h>