8282723: Add constructors taking a cause to JSSE exceptions

Reviewed-by: wetmore, iris
This commit is contained in:
Xue-Lei Andrew Fan 2022-03-20 06:46:13 +00:00
parent 3f923b82c3
commit 4df67426ed
30 changed files with 343 additions and 132 deletions

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 2018, 2019, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2018, 2022, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -154,8 +154,8 @@ enum SSLTrafficKeyDerivation implements SSLKeyDerivationGenerator {
ks.getKeyLength(cs),
ks.getAlgorithm(cs, algorithm));
} catch (GeneralSecurityException gse) {
throw (SSLHandshakeException)(new SSLHandshakeException(
"Could not generate secret").initCause(gse));
throw new SSLHandshakeException(
"Could not generate secret", gse);
}
}