| OLD | NEW | 
|---|
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be | 
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. | 
| 4 | 4 | 
| 5 #include "net/http/http_network_transaction.h" | 5 #include "net/http/http_network_transaction.h" | 
| 6 | 6 | 
| 7 #include <math.h>  // ceil | 7 #include <math.h>  // ceil | 
| 8 #include <vector> | 8 #include <vector> | 
| 9 | 9 | 
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" | 
| (...skipping 6539 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 6550   EXPECT_EQ(ERR_IO_PENDING, | 6550   EXPECT_EQ(ERR_IO_PENDING, | 
| 6551             connection->Init(host_port_pair.ToString(),tcp_params, LOWEST, | 6551             connection->Init(host_port_pair.ToString(),tcp_params, LOWEST, | 
| 6552                              &callback, session->tcp_socket_pool(), | 6552                              &callback, session->tcp_socket_pool(), | 
| 6553                              BoundNetLog())); | 6553                              BoundNetLog())); | 
| 6554   EXPECT_EQ(OK, callback.WaitForResult()); | 6554   EXPECT_EQ(OK, callback.WaitForResult()); | 
| 6555 | 6555 | 
| 6556   SSLConfig ssl_config; | 6556   SSLConfig ssl_config; | 
| 6557   session->ssl_config_service()->GetSSLConfig(&ssl_config); | 6557   session->ssl_config_service()->GetSSLConfig(&ssl_config); | 
| 6558   ClientSocket* socket = connection->release_socket(); | 6558   ClientSocket* socket = connection->release_socket(); | 
| 6559   socket = session->socket_factory()->CreateSSLClientSocket( | 6559   socket = session->socket_factory()->CreateSSLClientSocket( | 
| 6560       socket, "" , ssl_config, NULL /* ssl_host_info */); | 6560       socket, HostPortPair("" , 443), ssl_config, NULL /* ssl_host_info */); | 
| 6561   connection->set_socket(socket); | 6561   connection->set_socket(socket); | 
| 6562   EXPECT_EQ(ERR_IO_PENDING, socket->Connect(&callback)); | 6562   EXPECT_EQ(ERR_IO_PENDING, socket->Connect(&callback)); | 
| 6563   EXPECT_EQ(OK, callback.WaitForResult()); | 6563   EXPECT_EQ(OK, callback.WaitForResult()); | 
| 6564 | 6564 | 
| 6565   EXPECT_EQ(OK, spdy_session->InitializeWithSocket(connection.release(), | 6565   EXPECT_EQ(OK, spdy_session->InitializeWithSocket(connection.release(), | 
| 6566                                                    true, OK)); | 6566                                                    true, OK)); | 
| 6567 | 6567 | 
| 6568   trans.reset(new HttpNetworkTransaction(session)); | 6568   trans.reset(new HttpNetworkTransaction(session)); | 
| 6569 | 6569 | 
| 6570   rv = trans->Start(&request, &callback, BoundNetLog()); | 6570   rv = trans->Start(&request, &callback, BoundNetLog()); | 
| (...skipping 1169 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 7740   request.motivation = HttpRequestInfo::PRECONNECT_MOTIVATED; | 7740   request.motivation = HttpRequestInfo::PRECONNECT_MOTIVATED; | 
| 7741 | 7741 | 
| 7742   scoped_ptr<HttpNetworkTransaction> trans(new HttpNetworkTransaction(session)); | 7742   scoped_ptr<HttpNetworkTransaction> trans(new HttpNetworkTransaction(session)); | 
| 7743 | 7743 | 
| 7744   int rv = trans->Start(&request, &callback, BoundNetLog()); | 7744   int rv = trans->Start(&request, &callback, BoundNetLog()); | 
| 7745   EXPECT_EQ(ERR_IO_PENDING, rv); | 7745   EXPECT_EQ(ERR_IO_PENDING, rv); | 
| 7746   EXPECT_EQ(OK, callback.WaitForResult()); | 7746   EXPECT_EQ(OK, callback.WaitForResult()); | 
| 7747 } | 7747 } | 
| 7748 | 7748 | 
| 7749 }  // namespace net | 7749 }  // namespace net | 
| OLD | NEW | 
|---|