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

Side by Side Diff: src/trusted/debug_stub/transport.h

Issue 206493005: Provide chrome the option of learning the debug stub port chosen by nacl. (Closed) Base URL: svn://svn.chromium.org/native_client/trunk/src/native_client
Patch Set: Created 6 years, 9 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 /* 1 /*
2 * Copyright (c) 2010 The Native Client Authors. All rights reserved. 2 * Copyright (c) 2010 The Native Client Authors. All rights reserved.
3 * Use of this source code is governed by a BSD-style license that can be 3 * Use of this source code is governed by a BSD-style license that can be
4 * found in the LICENSE file. 4 * found in the LICENSE file.
5 */ 5 */
6 6
7 7
8 // This module provides interfaces for an IO stream. The stream is 8 // This module provides interfaces for an IO stream. The stream is
9 // expected to throw a std::exception if the stream is terminated on 9 // expected to throw a std::exception if the stream is terminated on
10 // either side. 10 // either side.
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 class SocketBinding { 42 class SocketBinding {
43 public: 43 public:
44 // Wrap existing socket handle. 44 // Wrap existing socket handle.
45 explicit SocketBinding(NaClSocketHandle socket_handle); 45 explicit SocketBinding(NaClSocketHandle socket_handle);
46 // Bind to the specified TCP port. 46 // Bind to the specified TCP port.
47 static SocketBinding *Bind(const char *addr); 47 static SocketBinding *Bind(const char *addr);
48 48
49 // Accept a connection on an already-bound TCP port. 49 // Accept a connection on an already-bound TCP port.
50 ITransport *AcceptConnection(); 50 ITransport *AcceptConnection();
51 51
52 // Get port the socket is bound to.
53 uint16_t GetBoundPort();
54
52 private: 55 private:
53 NaClSocketHandle socket_handle_; 56 NaClSocketHandle socket_handle_;
54 }; 57 };
55 58
56 } // namespace port 59 } // namespace port
57 60
58 #endif // NATIVE_CLIENT_PORT_TRANSPORT_H_ 61 #endif // NATIVE_CLIENT_PORT_TRANSPORT_H_
59 62
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698