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

Side by Side Diff: net/socket/socket_test_util.h

Issue 3107036: Fix a crash where we are checking IsConnected(). If you look into the ... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: nits, extra EXPECTS() in test cases added Created 10 years, 3 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 #ifndef NET_SOCKET_SOCKET_TEST_UTIL_H_ 5 #ifndef NET_SOCKET_SOCKET_TEST_UTIL_H_
6 #define NET_SOCKET_SOCKET_TEST_UTIL_H_ 6 #define NET_SOCKET_SOCKET_TEST_UTIL_H_
7 #pragma once 7 #pragma once
8 8
9 #include <cstring> 9 #include <cstring>
10 #include <deque> 10 #include <deque>
(...skipping 618 matching lines...) Expand 10 before | Expand all | Expand 10 after
629 MockSSLClientSocket( 629 MockSSLClientSocket(
630 net::ClientSocketHandle* transport_socket, 630 net::ClientSocketHandle* transport_socket,
631 const std::string& hostname, 631 const std::string& hostname,
632 const net::SSLConfig& ssl_config, 632 const net::SSLConfig& ssl_config,
633 net::SSLSocketDataProvider* socket); 633 net::SSLSocketDataProvider* socket);
634 ~MockSSLClientSocket(); 634 ~MockSSLClientSocket();
635 635
636 // ClientSocket methods: 636 // ClientSocket methods:
637 virtual int Connect(net::CompletionCallback* callback); 637 virtual int Connect(net::CompletionCallback* callback);
638 virtual void Disconnect(); 638 virtual void Disconnect();
639 virtual bool IsConnected() const;
639 640
640 // Socket methods: 641 // Socket methods:
641 virtual int Read(net::IOBuffer* buf, int buf_len, 642 virtual int Read(net::IOBuffer* buf, int buf_len,
642 net::CompletionCallback* callback); 643 net::CompletionCallback* callback);
643 virtual int Write(net::IOBuffer* buf, int buf_len, 644 virtual int Write(net::IOBuffer* buf, int buf_len,
644 net::CompletionCallback* callback); 645 net::CompletionCallback* callback);
645 646
646 // SSLClientSocket methods: 647 // SSLClientSocket methods:
647 virtual void GetSSLInfo(net::SSLInfo* ssl_info); 648 virtual void GetSSLInfo(net::SSLInfo* ssl_info);
648 virtual NextProtoStatus GetNextProto(std::string* proto); 649 virtual NextProtoStatus GetNextProto(std::string* proto);
(...skipping 213 matching lines...) Expand 10 before | Expand all | Expand 10 after
862 863
863 extern const char kSOCKS5OkRequest[]; 864 extern const char kSOCKS5OkRequest[];
864 extern const int kSOCKS5OkRequestLength; 865 extern const int kSOCKS5OkRequestLength;
865 866
866 extern const char kSOCKS5OkResponse[]; 867 extern const char kSOCKS5OkResponse[];
867 extern const int kSOCKS5OkResponseLength; 868 extern const int kSOCKS5OkResponseLength;
868 869
869 } // namespace net 870 } // namespace net
870 871
871 #endif // NET_SOCKET_SOCKET_TEST_UTIL_H_ 872 #endif // NET_SOCKET_SOCKET_TEST_UTIL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698