SettableTask.checkCompletingThread() only resets marker after match

Issue: SPR-15409
This commit is contained in:
Juergen Hoeller 2017-04-07 13:39:58 +02:00
parent e556aaccee
commit 8cb24e0d93
1 changed files with 3 additions and 1 deletions

View File

@ -169,7 +169,9 @@ public class SettableListenableFuture<T> implements ListenableFuture<T> {
private boolean checkCompletingThread() {
boolean check = (this.completingThread == Thread.currentThread());
this.completingThread = null; // only first check actually counts
if (check) {
this.completingThread = null; // only first match actually counts
}
return check;
}
}