| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_CURVECP_CLIENT_PACKETIZER_H_ | 5 #ifndef NET_CURVECP_CLIENT_PACKETIZER_H_ |
| 6 #define NET_CURVECP_CLIENT_PACKETIZER_H_ | 6 #define NET_CURVECP_CLIENT_PACKETIZER_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
| 10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| (...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 78 int ReadPackets(); | 78 int ReadPackets(); |
| 79 | 79 |
| 80 // Callback when an internal IO is completed. | 80 // Callback when an internal IO is completed. |
| 81 void OnIOComplete(int result); | 81 void OnIOComplete(int result); |
| 82 | 82 |
| 83 StateType next_state_; | 83 StateType next_state_; |
| 84 scoped_ptr<UDPClientSocket> socket_; | 84 scoped_ptr<UDPClientSocket> socket_; |
| 85 Packetizer::Listener* listener_; | 85 Packetizer::Listener* listener_; |
| 86 CompletionCallback user_callback_; | 86 CompletionCallback user_callback_; |
| 87 AddressList addresses_; | 87 AddressList addresses_; |
| 88 const struct addrinfo* current_address_; | 88 int current_address_index_; |
| 89 int hello_attempts_; // Number of attempts to send a Hello Packet. | 89 int hello_attempts_; // Number of attempts to send a Hello Packet. |
| 90 bool initiate_sent_; // Indicates whether the Initiate Packet was sent. | 90 bool initiate_sent_; // Indicates whether the Initiate Packet was sent. |
| 91 | 91 |
| 92 scoped_refptr<IOBuffer> read_buffer_; // Buffer for internal reads. | 92 scoped_refptr<IOBuffer> read_buffer_; // Buffer for internal reads. |
| 93 | 93 |
| 94 uchar shortterm_public_key_[32]; | 94 uchar shortterm_public_key_[32]; |
| 95 | 95 |
| 96 CompletionCallback io_callback_; | 96 CompletionCallback io_callback_; |
| 97 base::WeakPtrFactory<ClientPacketizer> weak_factory_; | 97 base::WeakPtrFactory<ClientPacketizer> weak_factory_; |
| 98 | 98 |
| 99 DISALLOW_COPY_AND_ASSIGN(ClientPacketizer); | 99 DISALLOW_COPY_AND_ASSIGN(ClientPacketizer); |
| 100 }; | 100 }; |
| 101 | 101 |
| 102 } // namespace net | 102 } // namespace net |
| 103 | 103 |
| 104 #endif // NET_CURVECP_CLIENT_PACKETIZER_H_ | 104 #endif // NET_CURVECP_CLIENT_PACKETIZER_H_ |
| OLD | NEW |