summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul Phillips <paulp@improving.org>2011-05-21 17:45:44 +0000
committerPaul Phillips <paulp@improving.org>2011-05-21 17:45:44 +0000
commit3e75e7e462b27fcf64185c08eb10cce5166c9d26 (patch)
treefca3daa82b2eb16f46c2905d20c5cc86c5c00f82
parent390f2d52aef0785f745a52121685b0ef2e0699c4 (diff)
downloadscala-3e75e7e462b27fcf64185c08eb10cce5166c9d26.tar.gz
scala-3e75e7e462b27fcf64185c08eb10cce5166c9d26.tar.bz2
scala-3e75e7e462b27fcf64185c08eb10cce5166c9d26.zip
Commented out a bug workaround which seems to b...
Commented out a bug workaround which seems to be too costly to impose on the general case. No review.
-rw-r--r--src/compiler/scala/tools/nsc/io/File.scala31
1 files changed, 17 insertions, 14 deletions
diff --git a/src/compiler/scala/tools/nsc/io/File.scala b/src/compiler/scala/tools/nsc/io/File.scala
index b11151ab7e..7086c65ea3 100644
--- a/src/compiler/scala/tools/nsc/io/File.scala
+++ b/src/compiler/scala/tools/nsc/io/File.scala
@@ -43,20 +43,23 @@ object File {
// trigger java.lang.InternalErrors later when using it concurrently. We ignore all
// the exceptions so as not to cause spurious failures when no write access is available,
// e.g. google app engine.
- try {
- import Streamable.closing
- val tmp = JFile.createTempFile("bug6503430", null, null)
- try closing(new FileInputStream(tmp)) { in =>
- val inc = in.getChannel()
- closing(new FileOutputStream(tmp, true)) { out =>
- out.getChannel().transferFrom(inc, 0, 0)
- }
- }
- finally tmp.delete()
- }
- catch {
- case _: IllegalArgumentException | _: IllegalStateException | _: IOException | _: SecurityException => ()
- }
+ //
+ // XXX need to put this behind a setting.
+ //
+ // try {
+ // import Streamable.closing
+ // val tmp = JFile.createTempFile("bug6503430", null, null)
+ // try closing(new FileInputStream(tmp)) { in =>
+ // val inc = in.getChannel()
+ // closing(new FileOutputStream(tmp, true)) { out =>
+ // out.getChannel().transferFrom(inc, 0, 0)
+ // }
+ // }
+ // finally tmp.delete()
+ // }
+ // catch {
+ // case _: IllegalArgumentException | _: IllegalStateException | _: IOException | _: SecurityException => ()
+ // }
}
import File._
import Path._