We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents f1228bb + 80b24e9 commit cea4471Copy full SHA for cea4471
library/src/scala/concurrent/BatchingExecutor.scala
@@ -60,7 +60,7 @@ private[concurrent] trait BatchingExecutor extends Executor {
60
parentBlockContext = prevBlockContext
61
62
@tailrec def processBatch(batch: List[Runnable]): Unit = batch match {
63
- case Nil => ()
+ case null | Nil => ()
64
case head :: tail =>
65
_tasksLocal set tail
66
try {
@@ -91,7 +91,7 @@ private[concurrent] trait BatchingExecutor extends Executor {
91
// if we know there will be blocking, we don't want to keep tasks queued up because it could deadlock.
92
{
93
val tasks = _tasksLocal.get
94
- _tasksLocal set Nil
+ _tasksLocal set null
95
if ((tasks ne null) && tasks.nonEmpty)
96
unbatchedExecute(new Batch(tasks))
97
}
0 commit comments