Fix NPE in TrapExit due to improper scoping of null check.

This commit is contained in:
Mark Harrah 2013-10-08 18:41:13 -04:00
parent 97e5ac8ec1
commit 0781cee4b3
1 changed files with 4 additions and 3 deletions

View File

@ -242,10 +242,11 @@ private final class TrapExit(delegateManager: SecurityManager) extends SecurityM
val t = tref.get
if( (t eq null) || isDone(t))
unregister(id)
else
else {
f(t)
if(isDone(t))
unregister(id)
if(isDone(t))
unregister(id)
}
}
}
}