Hi there,

While running mauve test, I found the following errors which does not fixed in
classpath-0.9 release, either.

in native/jni/java-net/gnu_java_net_PlainDatagramSocketImpl.c, 
Java_gnu_java_net_PlainDatagramSocketImpl_receive0() calls ntohs() on the port
before "setPort:(I)V" method call which is not correct.
_javanet_recvfrom() itself handles the endian conversions.

here's the patch.

diff -uu 
classpath-0.08/native/jni/java-net/gnu_java_net_PlainDatagramSocketImpl.c.\~1\~ 
classpath-0.08/native/jni/java-net/gnu_java_net_PlainDatagramSocketImpl.c
--- classpath-0.08/native/jni/java-net/gnu_java_net_PlainDatagramSocketImpl.c.~1~      
 2003-11-29 08:43:18.000000000 +0900
+++ classpath-0.08/native/jni/java-net/gnu_java_net_PlainDatagramSocketImpl.c   
2004-05-20 20:26:57.000000000 +0900
@@ -299,7 +299,7 @@
   DBG("PlainDatagramSocketImpl.receive(): Stored the address\n");
 
   /* Store the port */
-  port = ntohs(((unsigned short)port));
+  /* port = ntohs(((unsigned short)port)); */
 
   mid = (*env)->GetMethodID(env, cls, "setPort", "(I)V");
   if (mid == NULL)

Diff finished.  Fri May 21 09:48:55 2004



_______________________________________________
Classpath mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/classpath

Reply via email to