This is the mail archive of the java-patches@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

added typedef for socklen_t to win32.h


Win32 doesn't define socklen_t; it thinks that accept() is:

   SOCKET PASCAL accept(SOCKET,struct sockaddr*,int*);

Hence:

I'd like to commit this to the 3.3 branch; without it, you can't
crossbuild from Linux to Win32.  Ok for branch?

  - a

2003-02-11  Adam Megacz  <adam@xwt.org>

        * include/win32.h: added typedef for socklen_t

Index: include/win32.h
===================================================================
RCS file: /cvs/gcc/gcc/libjava/include/win32.h,v
retrieving revision 1.16.2.3
diff -u -r1.16.2.3 win32.h
--- include/win32.h     28 Jan 2003 19:10:57 -0000      1.16.2.3
+++ include/win32.h     12 Feb 2003 06:54:06 -0000
@@ -28,6 +28,8 @@
 
 #ifndef DISABLE_JAVA_NET
 
+typedef int socklen_t;
+
 // these errors cannot occur on Win32
 #define ENOTCONN 0
 #define ECONNRESET 0


-- 
"The master in the art of living makes little distinction between his
 work and his play, his labor and his leisure, his mind and his body,
 his education and his recreation, his love and his religion. He hardly
 knows which is which; he simply pursues his vision of excellence in
 whatever he does, leaving others to decide whether he is working or
 playing. To him he is always doing both."       -- Zen Buddhist Text


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]