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

Unified Diff: native_client_sdk/src/libraries/nacl_io/mount_node_tty.h

Issue 23498015: [NaCl SDK] Support non blocking TCP/UDP (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merge Created 7 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 side-by-side diff with in-line comments
Download patch
Index: native_client_sdk/src/libraries/nacl_io/mount_node_tty.h
diff --git a/native_client_sdk/src/libraries/nacl_io/mount_node_tty.h b/native_client_sdk/src/libraries/nacl_io/mount_node_tty.h
index c8070b9d5fb722feb87a7a61b31a4fbd7986203a..1c8e65d3925e2ddf0d368471d2841197ce47de6f 100644
--- a/native_client_sdk/src/libraries/nacl_io/mount_node_tty.h
+++ b/native_client_sdk/src/libraries/nacl_io/mount_node_tty.h
@@ -20,7 +20,8 @@ namespace nacl_io {
class MountNodeTty : public MountNodeCharDevice {
public:
explicit MountNodeTty(Mount* mount);
- ~MountNodeTty();
+
+ virtual EventEmitter* GetEventEmitter();
virtual Error Ioctl(int request,
char* arg);
@@ -39,21 +40,14 @@ class MountNodeTty : public MountNodeCharDevice {
virtual Error Tcsetattr(int optional_actions,
const struct termios *termios_p);
- virtual uint32_t GetEventStatus() {
- uint32_t status = POLLOUT;
- if (is_readable_)
- status |= POLLIN;
- return status;
- }
-
private:
+ ScopedEventEmitter emitter_;
+
Error ProcessInput(struct tioc_nacl_input_string* message);
Error Echo(const char* string, int count);
void InitTermios();
std::deque<char> input_buffer_;
- bool is_readable_;
- pthread_cond_t is_readable_cond_;
struct termios termios_;
/// Current height of terminal in rows. Set via ioctl(2).
« no previous file with comments | « native_client_sdk/src/libraries/nacl_io/mount_node_tcp.cc ('k') | native_client_sdk/src/libraries/nacl_io/mount_node_tty.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698