From caaf0ccfc3d634f8ddf0f68db4d19ee1775a1f25 Mon Sep 17 00:00:00 2001 From: sponge <sponge@mail.i2p> Date: Wed, 8 Oct 2008 14:28:35 +0000 Subject: [PATCH] Additional BOB fixes. Added BOB to clients.config and wrapper.config for new installs. --- apps/BOB/src/net/i2p/BOB/BOB.java | 1 + apps/BOB/src/net/i2p/BOB/I2PtoTCP.java | 2 -- apps/BOB/src/net/i2p/BOB/TCPio.java | 2 +- apps/BOB/src/net/i2p/BOB/TCPtoI2P.java | 7 +++---- installer/resources/clients.config | 6 ++++++ installer/resources/wrapper.config | 2 ++ 6 files changed, 13 insertions(+), 7 deletions(-) diff --git a/apps/BOB/src/net/i2p/BOB/BOB.java b/apps/BOB/src/net/i2p/BOB/BOB.java index ab29f64445..b9b48dcfa7 100644 --- a/apps/BOB/src/net/i2p/BOB/BOB.java +++ b/apps/BOB/src/net/i2p/BOB/BOB.java @@ -138,6 +138,7 @@ public class BOB { } try { + warn("BOB is now running."); ServerSocket listener = new ServerSocket(Integer.parseInt(props.getProperty(PROP_BOB_PORT)), 10, InetAddress.getByName(props.getProperty(PROP_BOB_HOST))); Socket server; diff --git a/apps/BOB/src/net/i2p/BOB/I2PtoTCP.java b/apps/BOB/src/net/i2p/BOB/I2PtoTCP.java index b62e5b782f..b862db10aa 100644 --- a/apps/BOB/src/net/i2p/BOB/I2PtoTCP.java +++ b/apps/BOB/src/net/i2p/BOB/I2PtoTCP.java @@ -23,11 +23,9 @@ */ package net.i2p.BOB; -import java.io.IOException; import java.io.InputStream; import java.io.OutputStream; import java.net.Socket; -import java.net.UnknownHostException; import net.i2p.client.streaming.I2PSocket; /** diff --git a/apps/BOB/src/net/i2p/BOB/TCPio.java b/apps/BOB/src/net/i2p/BOB/TCPio.java index 460f8aa58d..3b32aae1b0 100644 --- a/apps/BOB/src/net/i2p/BOB/TCPio.java +++ b/apps/BOB/src/net/i2p/BOB/TCPio.java @@ -80,7 +80,7 @@ public class TCPio implements Runnable { /* according to the specs: * * The total number of bytes read into the buffer, - * or -1 is there is no more data because the end of + * or -1 if there is no more data because the end of * the stream has been reached. * */ diff --git a/apps/BOB/src/net/i2p/BOB/TCPtoI2P.java b/apps/BOB/src/net/i2p/BOB/TCPtoI2P.java index 51d279ee4b..ee21f462eb 100644 --- a/apps/BOB/src/net/i2p/BOB/TCPtoI2P.java +++ b/apps/BOB/src/net/i2p/BOB/TCPtoI2P.java @@ -100,12 +100,10 @@ public class TCPtoI2P implements Runnable { * @throws java.io.IOException */ private void Emsg(String e, OutputStream out) throws IOException { - System.out.println("ERROR TCPtoI2P: " + e); +// Debugging System.out.println("ERROR TCPtoI2P: " + e); out.write("ERROR".concat(e).getBytes()); out.write(13); // cr out.flush(); - sock.close(); - } /** @@ -152,7 +150,8 @@ public class TCPtoI2P implements Runnable { // nop } } - } catch(I2PException e) { + + } catch(I2PException e) { Emsg("ERROR " + e.toString(), out); } catch(ConnectException e) { Emsg("ERROR " + e.toString(), out); diff --git a/installer/resources/clients.config b/installer/resources/clients.config index e756acc50b..4b8a4c3692 100644 --- a/installer/resources/clients.config +++ b/installer/resources/clients.config @@ -25,3 +25,9 @@ clientApp.4.main=net.i2p.apps.systray.UrlLauncher clientApp.4.name=consoleBrowser clientApp.4.args=http://localhost:7657/ clientApp.4.delay=5 + +# Start up BOB +clientApp.5.args= +clientApp.5.delay=10 +clientApp.5.main=net.i2p.BOB.BOB +clientApp.5.name=BOB diff --git a/installer/resources/wrapper.config b/installer/resources/wrapper.config index f931efaf0b..86fdce2eb0 100644 --- a/installer/resources/wrapper.config +++ b/installer/resources/wrapper.config @@ -48,6 +48,8 @@ wrapper.java.classpath.17=lib/wrapper.jar # systray, LGPL wrapper.java.classpath.18=lib/systray.jar wrapper.java.classpath.19=lib/systray4j.jar +# BOB +wrapper.java.classpath.20=lib/BOB.jar # Java Library Path (location of Wrapper.DLL or libwrapper.so) wrapper.java.library.path.1=. -- GitLab