summaryrefslogtreecommitdiff
path: root/src/library
diff options
context:
space:
mode:
authorJosh Suereth <Joshua.Suereth@gmail.com>2012-10-31 08:08:55 -0700
committerJosh Suereth <Joshua.Suereth@gmail.com>2012-10-31 08:08:55 -0700
commit1f9124b74566efe82e1c4f8d33fcd8618ea0f599 (patch)
tree079df2da67f96bf4839a65d2d6f3e431f5fd6dfa /src/library
parentd3f2d6da5da059a7d7566a073a55264ae933b857 (diff)
parentc7c79c83b5a7560df60ba9b4578bbce02514a22a (diff)
downloadscala-1f9124b74566efe82e1c4f8d33fcd8618ea0f599.tar.gz
scala-1f9124b74566efe82e1c4f8d33fcd8618ea0f599.tar.bz2
scala-1f9124b74566efe82e1c4f8d33fcd8618ea0f599.zip
Merge pull request #1522 from possiblywrong/2.10.x
SI-6488: Fix for race with open I/O fds
Diffstat (limited to 'src/library')
-rw-r--r--src/library/scala/sys/process/ProcessImpl.scala5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/library/scala/sys/process/ProcessImpl.scala b/src/library/scala/sys/process/ProcessImpl.scala
index cdf7d72caa..84ef5f277b 100644
--- a/src/library/scala/sys/process/ProcessImpl.scala
+++ b/src/library/scala/sys/process/ProcessImpl.scala
@@ -222,7 +222,10 @@ private[process] trait ProcessImpl {
p.exitValue()
}
override def destroy() = {
- try p.destroy()
+ try{
+ outputThreads foreach (_.stop())
+ p.destroy()
+ }
finally inputThread.interrupt()
}
}