Skip to content

Commit

Permalink
[java] Restoring thread interruption status before rethrowing an exce…
Browse files Browse the repository at this point in the history
…ption
  • Loading branch information
barancev committed Mar 22, 2020
1 parent 98f589b commit 381608d
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,7 @@ public <V> V until(Function<? super T, V> isTrue) {

throw new RuntimeException(cause);
} catch (InterruptedException cause) {
Thread.currentThread().interrupt();
throw new RuntimeException(cause);
} catch (java.util.concurrent.TimeoutException cause) {
throw new TimeoutException("Supplied function might have stalled", cause);
Expand Down

0 comments on commit 381608d

Please sign in to comment.