From: <ls...@us...> - 2007-09-21 21:06:26
|
Revision: 3515 http://jnode.svn.sourceforge.net/jnode/?rev=3515&view=rev Author: lsantha Date: 2007-09-21 14:06:24 -0700 (Fri, 21 Sep 2007) Log Message: ----------- Enabled networking support for isolates. Modified Paths: -------------- trunk/core/src/classpath/java/java/net/ServerSocket.java trunk/core/src/classpath/java/java/net/Socket.java trunk/distr/src/apps/fi/iki/elonen/NanoHTTPD.java trunk/net/src/net/org/jnode/net/command/PingCommand.java Modified: trunk/core/src/classpath/java/java/net/ServerSocket.java =================================================================== --- trunk/core/src/classpath/java/java/net/ServerSocket.java 2007-09-21 08:41:58 UTC (rev 3514) +++ trunk/core/src/classpath/java/java/net/ServerSocket.java 2007-09-21 21:06:24 UTC (rev 3515) @@ -43,11 +43,11 @@ import java.io.IOException; import java.nio.channels.IllegalBlockingModeException; import java.nio.channels.ServerSocketChannel; +import org.jnode.vm.annotation.SharedStatics; - /* Written using on-line Java Platform 1.2 API Specification. - * Status: I believe all methods are implemented. - */ +* Status: I believe all methods are implemented. +*/ /** * This class models server side sockets. The basic model is that the @@ -62,6 +62,7 @@ * @author Aaron M. Renn (ar...@ur...) * @author Per Bothner (bo...@cy...) */ +@SharedStatics public class ServerSocket { /** Modified: trunk/core/src/classpath/java/java/net/Socket.java =================================================================== --- trunk/core/src/classpath/java/java/net/Socket.java 2007-09-21 08:41:58 UTC (rev 3514) +++ trunk/core/src/classpath/java/java/net/Socket.java 2007-09-21 21:06:24 UTC (rev 3515) @@ -45,11 +45,11 @@ import java.io.OutputStream; import java.nio.channels.IllegalBlockingModeException; import java.nio.channels.SocketChannel; +import org.jnode.vm.annotation.SharedStatics; - /* Written using on-line Java Platform 1.2 API Specification. - * Status: I believe all methods are implemented. - */ +* Status: I believe all methods are implemented. +*/ /** * This class models a client site socket. A socket is a TCP/IP endpoint @@ -68,6 +68,7 @@ * @author Aaron M. Renn (ar...@ur...) * @author Per Bothner (bo...@cy...) */ +@SharedStatics public class Socket { /** @@ -368,17 +369,20 @@ } catch (IOException exception) { - close(); + exception.printStackTrace(); + close(); throw exception; } catch (RuntimeException exception) { - close(); + exception.printStackTrace(); + close(); throw exception; } catch (Error error) { - close(); + error.printStackTrace(); + close(); throw error; } } Modified: trunk/distr/src/apps/fi/iki/elonen/NanoHTTPD.java =================================================================== --- trunk/distr/src/apps/fi/iki/elonen/NanoHTTPD.java 2007-09-21 08:41:58 UTC (rev 3514) +++ trunk/distr/src/apps/fi/iki/elonen/NanoHTTPD.java 2007-09-21 21:06:24 UTC (rev 3515) @@ -251,8 +251,9 @@ } catch( IOException ioe ) { - System.err.println( "Couldn't start server:\n" + ioe ); - System.exit( -1 ); + System.err.println( "Couldn't start server:\n"); + ioe.printStackTrace(); + System.exit( -1 ); } nh.myFileDir = new File(""); Modified: trunk/net/src/net/org/jnode/net/command/PingCommand.java =================================================================== --- trunk/net/src/net/org/jnode/net/command/PingCommand.java 2007-09-21 08:41:58 UTC (rev 3514) +++ trunk/net/src/net/org/jnode/net/command/PingCommand.java 2007-09-21 21:06:24 UTC (rev 3515) @@ -43,6 +43,7 @@ import org.jnode.shell.help.ParsedArguments; import org.jnode.shell.help.Syntax; import org.jnode.shell.help.argument.HostNameArgument; +import org.jnode.vm.annotation.SharedStatics; /** * @author JPG @@ -167,7 +168,7 @@ this.stat.recordPacket(roundtrip); } } - +@SharedStatics class Request extends TimerTask { private static Map<Integer, Request> requests = new HashMap<Integer, Request>(); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |