mbenson 2004/02/20 10:07:44
Modified: src/main/org/apache/tools/ant/util LazyFileOutputStream.java
Log:
Fix occasionally thrown IOException when the stream has already been closed
with alwaysCreate.
Revision Changes Path
1.6 +1 -1
ant/src/main/org/apache/tools/ant/util/LazyFileOutputStream.java
Index: LazyFileOutputStream.java
===================================================================
RCS file:
/home/cvs/ant/src/main/org/apache/tools/ant/util/LazyFileOutputStream.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- LazyFileOutputStream.java 16 Feb 2004 19:33:34 -0000 1.5
+++ LazyFileOutputStream.java 20 Feb 2004 18:07:44 -0000 1.6
@@ -93,7 +93,7 @@
}
public synchronized void close() throws IOException {
- if (alwaysCreate) {
+ if (alwaysCreate && !closed) {
ensureOpened();
}
if (opened) {
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]