--- a/jdk/src/share/classes/sun/security/ssl/Handshaker.java Mon Aug 15 12:56:01 2011 -0700
+++ b/jdk/src/share/classes/sun/security/ssl/Handshaker.java Mon Aug 15 11:48:20 2011 -0700
@@ -154,7 +154,7 @@
* Data is protected by the SSLEngine.this lock.
*/
private volatile boolean taskDelegated = false;
- private volatile DelegatedTask delegatedTask = null;
+ private volatile DelegatedTask<?> delegatedTask = null;
private volatile Exception thrown = null;
// Could probably use a java.util.concurrent.atomic.AtomicReference
@@ -1316,7 +1316,7 @@
thrown = null;
}
- DelegatedTask getTask() {
+ DelegatedTask<?> getTask() {
if (!taskDelegated) {
taskDelegated = true;
return delegatedTask;
@@ -1358,8 +1358,7 @@
thrown = null;
if (e instanceof RuntimeException) {
- throw (RuntimeException)
- new RuntimeException(msg).initCause(e);
+ throw new RuntimeException(msg, e);
} else if (e instanceof SSLHandshakeException) {
throw (SSLHandshakeException)
new SSLHandshakeException(msg).initCause(e);
@@ -1377,8 +1376,7 @@
* If it's SSLException or any other Exception,
* we'll wrap it in an SSLException.
*/
- throw (SSLException)
- new SSLException(msg).initCause(e);
+ throw new SSLException(msg, e);
}
}
}