@Override
    public void uncaughtException(Thread thread, Throwable ex) {
      if (firstException == null) {
        firstException = ex;
      }
    }
Exception handler for uncaught exceptions in a thread.

<p>TODO(bleichen): Surely there must be a better way to catch exceptions in threads in unit
tests. junit ought to do this. However, at least for some setups, tests can pass despite
uncaught exceptions in threads.

<p>TODO(bleichen): Nonce reuse of non-deterministic signatures.

<p>TODO(bleichen): Overwriting nonces in deterministic signature schemes.
java_src/src/test/java/com/google/crypto/tink/subtle/SignatureThreadSafetyTest.java