[kaffe] CVS kaffe (jim): Fix -- only register network interfaces that have an IPv4 or IPv6 address.

Kaffe CVS cvs-commits at kaffe.org
Mon Sep 1 18:00:03 PDT 2003


PatchSet 4010 
Date: 2003/09/02 00:53:58
Author: jim
Branch: HEAD
Tag: (none) 
Log:
Fix -- only register network interfaces that have an IPv4 or IPv6 address.

Members: 
	ChangeLog:1.1606->1.1607 
	libraries/clib/net/NetworkInterface.c:1.3->1.4 

Index: kaffe/ChangeLog
diff -u kaffe/ChangeLog:1.1606 kaffe/ChangeLog:1.1607
--- kaffe/ChangeLog:1.1606	Mon Sep  1 20:28:00 2003
+++ kaffe/ChangeLog	Tue Sep  2 00:53:58 2003
@@ -1,5 +1,11 @@
 2003-09-01  Jim Pick  <jim at kaffe.org>
 
+	* libraries/clib/net/NetworkInterface.c:
+	Really ignore non-IPv4/IPv6 interfaces (fixes NetworkInterfaceTest
+	regression test).
+
+2003-09-01  Jim Pick  <jim at kaffe.org>
+
 	* kaffe/kaffevm/jni.c:
 	Change casts to avoid "type punning" warnings in gcc 3.x.
 
Index: kaffe/libraries/clib/net/NetworkInterface.c
diff -u kaffe/libraries/clib/net/NetworkInterface.c:1.3 kaffe/libraries/clib/net/NetworkInterface.c:1.4
--- kaffe/libraries/clib/net/NetworkInterface.c:1.3	Sun Aug 31 17:16:49 2003
+++ kaffe/libraries/clib/net/NetworkInterface.c	Tue Sep  2 00:54:00 2003
@@ -113,9 +113,10 @@
 	    }
 	}
     }
-  retval = (struct Hjava_net_InetAddress *)do_execute_java_class_method
-    ("java/net/InetAddress", 0, "getByName", "(Ljava/lang/String;)Ljava/net/InetAddress;",
-     address_string).l;
+  if (address_string)
+    retval = (struct Hjava_net_InetAddress *)do_execute_java_class_method
+      ("java/net/InetAddress", 0, "getByName", "(Ljava/lang/String;)Ljava/net/InetAddress;",
+       address_string).l;
   return( retval );
 }
 




More information about the kaffe mailing list