Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(206)

Unified Diff: sdk/lib/io/secure_socket.dart

Issue 262833002: Use Socket::connect for SecureSocket as well. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/io/secure_socket.dart
diff --git a/sdk/lib/io/secure_socket.dart b/sdk/lib/io/secure_socket.dart
index b966c61bb676e30fba59043ffbe18e96e8449573..903ecf8b0f6132200f3559dd8d51ff473c30a45f 100644
--- a/sdk/lib/io/secure_socket.dart
+++ b/sdk/lib/io/secure_socket.dart
@@ -246,13 +246,23 @@ abstract class RawSecureSocket implements RawSocket {
{bool sendClientCertificate: false,
String certificateName,
bool onBadCertificate(X509Certificate certificate)}) {
- return _RawSecureSocket.connect(
+ _RawSecureSocket._verifyFields(
host,
port,
certificateName,
- is_server: false,
- sendClientCertificate: sendClientCertificate,
- onBadCertificate: onBadCertificate);
+ false,
+ false,
+ false,
+ sendClientCertificate,
+ onBadCertificate);
+ return RawSocket.connect(host, port)
+ .then((socket) {
+ return secure(socket,
+ host: host,
+ sendClientCertificate: sendClientCertificate,
+ certificateName: certificateName,
+ onBadCertificate: onBadCertificate);
+ });
}
/**
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698