aboutsummaryrefslogtreecommitdiff
path: root/tmux.h
diff options
context:
space:
mode:
Diffstat (limited to 'tmux.h')
-rw-r--r--tmux.h26
1 files changed, 8 insertions, 18 deletions
diff --git a/tmux.h b/tmux.h
index f0676749..cbb6434a 100644
--- a/tmux.h
+++ b/tmux.h
@@ -1,4 +1,4 @@
-/* $Id: tmux.h,v 1.409 2009-08-11 14:42:59 nicm Exp $ */
+/* $Id: tmux.h,v 1.410 2009-08-14 21:04:04 tcunha Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
@@ -21,10 +21,11 @@
#include "config.h"
-#define PROTOCOL_VERSION -15
+#define PROTOCOL_VERSION 1
#include <sys/param.h>
#include <sys/time.h>
+#include <sys/uio.h>
#include <limits.h>
#include <signal.h>
@@ -34,6 +35,7 @@
#include <termios.h>
#include "array.h"
+#include "imsg.h"
#include "compat.h"
@@ -302,23 +304,16 @@ enum msgtype {
MSG_SHUTDOWN,
MSG_SUSPEND,
MSG_UNLOCK,
+ MSG_VERSION,
MSG_WAKEUP,
MSG_ENVIRON
};
/*
- * Message header and data.
+ * Message data.
*
* Don't forget to bump PROTOCOL_VERSION if any of these change!
- *
- * Changing sizeof (struct hdr) or sizeof (struct msg_identify_data) will make
- * the tmux client hang even if the protocol version is bumped.
*/
-struct hdr {
- enum msgtype type;
- size_t size;
-};
-
struct msg_print_data {
char msg[PRINT_LENGTH];
};
@@ -333,7 +328,6 @@ struct msg_command_data {
struct msg_identify_data {
char tty[TTY_NAME_MAX];
- int version;
char cwd[MAXPATHLEN];
@@ -907,9 +901,7 @@ struct tty_ctx {
/* Client connection. */
struct client {
- int fd;
- struct buffer *in;
- struct buffer *out;
+ struct imsgbuf ibuf;
struct environ environ;
@@ -957,9 +949,7 @@ ARRAY_DECL(clients, struct client *);
/* Client context. */
struct client_ctx {
- int srv_fd;
- struct buffer *srv_in;
- struct buffer *srv_out;
+ struct imsgbuf ibuf;
enum {
CCTX_DETACH,