Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ open class Platform {
open fun getHandshakeServerNames(sslSocket: SSLSocket): List<String> {
val session = sslSocket.session as? ExtendedSSLSession ?: return listOf()
return try {
session.requestedServerNames.mapNotNull { (it as? SNIHostName)?.asciiName }
(session.requestedServerNames ?: emptyList()).mapNotNull { (it as? SNIHostName)?.asciiName }
} catch (_: UnsupportedOperationException) {
// UnsupportedOperationException – if the underlying provider does not implement the operation
// https://github.com/bcgit/bc-java/issues/1773
Expand Down
Loading