From 71aaf03d09b0633402460725e60c12b4e58212ce Mon Sep 17 00:00:00 2001 From: jrandom Date: Thu, 28 Jun 2007 01:51:16 +0000 Subject: [PATCH] 2007-06-27 jrandom * fix for a streaming lib bug that could leave a thread waiting indefinitely (thanks Complication!) --- .../src/net/i2p/client/streaming/I2PSocketFull.java | 12 +++++++++--- history.txt | 6 +++++- router/java/src/net/i2p/router/RouterVersion.java | 4 ++-- 3 files changed, 16 insertions(+), 6 deletions(-) diff --git a/apps/streaming/java/src/net/i2p/client/streaming/I2PSocketFull.java b/apps/streaming/java/src/net/i2p/client/streaming/I2PSocketFull.java index 48aece1849..61dd487578 100644 --- a/apps/streaming/java/src/net/i2p/client/streaming/I2PSocketFull.java +++ b/apps/streaming/java/src/net/i2p/client/streaming/I2PSocketFull.java @@ -29,9 +29,15 @@ public class I2PSocketFull implements I2PSocket { if (c == null) return; if (c.getIsConnected()) { OutputStream out = c.getOutputStream(); - if (out != null) - out.close(); - c.disconnect(true); + if (out != null) { + try { + out.close(); + } catch (IOException ioe) { + // ignore any write error, as we want to keep on and kill the + // con (thanks Complication!) + } + } + c.disconnect(true); } else { //throw new IOException("Not connected"); } diff --git a/history.txt b/history.txt index f8d56bd755..c0f04d4f64 100644 --- a/history.txt +++ b/history.txt @@ -1,4 +1,8 @@ -$Id: history.txt,v 1.568 2007-05-06 15:02:04 complication Exp $ +$Id: history.txt,v 1.569 2007-06-16 18:15:49 complication Exp $ + +2007-06-27 jrandom + * fix for a streaming lib bug that could leave a thread waiting + indefinitely (thanks Complication!) 2007-06-16 Complication * First pass on EepGet and ReseedHandler improvements, diff --git a/router/java/src/net/i2p/router/RouterVersion.java b/router/java/src/net/i2p/router/RouterVersion.java index 01ae5655b4..05425bd71b 100644 --- a/router/java/src/net/i2p/router/RouterVersion.java +++ b/router/java/src/net/i2p/router/RouterVersion.java @@ -15,9 +15,9 @@ import net.i2p.CoreVersion; * */ public class RouterVersion { - public final static String ID = "$Revision: 1.503 $ $Date: 2007-05-06 14:52:43 $"; + public final static String ID = "$Revision: 1.504 $ $Date: 2007-06-16 18:15:51 $"; public final static String VERSION = "0.6.1.28"; - public final static long BUILD = 6; + public final static long BUILD = 7; public static void main(String args[]) { System.out.println("I2P Router version: " + VERSION + "-" + BUILD); System.out.println("Router ID: " + RouterVersion.ID);