summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaryl Lee <dlee@altaregos.com>2002-12-26 01:21:25 +0000
committerDaryl Lee <dlee@altaregos.com>2002-12-26 01:21:25 +0000
commit3f93e18604951f8d8d8456dc46c559b8a0e4d834 (patch)
tree5d3e167b89c34e58adf138728ddceaeeb5034edc
parent77350add0477f9951ee3664ca12030f5cf9ce909 (diff)
downloadclasspath-3f93e18604951f8d8d8456dc46c559b8a0e4d834.tar.gz
java/io/PipedOutputStreaml.java: corrected connect() for test of previous connection
-rw-r--r--ChangeLog5
-rw-r--r--java/io/PipedOutputStream.java2
2 files changed, 6 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 4a7e3c1f8..fee50cd05 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2002-12-25 Daryl Lee <dolee@sources.redhat.com>
+
+ * java/io/PipedOutputStream.java: corrected connect(); test to check if
+ already connected was invalid.
+
2002-12-24 Mark Wielaard <mark@klomp.org>
* java/util/Properties.java (formatForOutput): Don't fall
diff --git a/java/io/PipedOutputStream.java b/java/io/PipedOutputStream.java
index b819f309c..68b656b19 100644
--- a/java/io/PipedOutputStream.java
+++ b/java/io/PipedOutputStream.java
@@ -97,7 +97,7 @@ public class PipedOutputStream extends OutputStream
*/
public void connect(PipedInputStream sink) throws IOException
{
- if (sink != null)
+ if (this.sink != null || sink.source != null)
throw new IOException ("Already connected");
sink.connect(this);
}