summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNicholas Marriott <nicholas.marriott@gmail.com>2007-10-03 09:17:00 +0000
committerNicholas Marriott <nicholas.marriott@gmail.com>2007-10-03 09:17:00 +0000
commit7ccdbf392d87fc7ad9e79dc5a642c415386a72aa (patch)
tree2cb09deefc5e96b7e0f0393d97b05ef4eb0ba035
parentef91aac6887e82b77ca3dff8bcffaffab0a8ec08 (diff)
Sprinkle some const.
-rw-r--r--input.c4
-rw-r--r--server-msg.c6
-rw-r--r--tmux.c6
3 files changed, 8 insertions, 8 deletions
diff --git a/input.c b/input.c
index 3f3d7f9c..ea589a0b 100644
--- a/input.c
+++ b/input.c
@@ -1,4 +1,4 @@
-/* $Id: input.c,v 1.17 2007-10-03 00:13:46 nicm Exp $ */
+/* $Id: input.c,v 1.18 2007-10-03 09:16:59 nicm Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
@@ -24,7 +24,7 @@
#include "tmux.h"
-struct {
+const struct {
u_char first;
u_char last;
enum input_class class;
diff --git a/server-msg.c b/server-msg.c
index 1b9cd3fb..bf7af9de 100644
--- a/server-msg.c
+++ b/server-msg.c
@@ -1,4 +1,4 @@
-/* $Id: server-msg.c,v 1.14 2007-10-02 17:45:05 nicm Exp $ */
+/* $Id: server-msg.c,v 1.15 2007-10-03 09:17:00 nicm Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
@@ -45,7 +45,7 @@ struct server_msg {
int (*fn)(struct hdr *, struct client *);
};
-struct server_msg server_msg_table[] = {
+const struct server_msg server_msg_table[] = {
{ MSG_ATTACH, server_msg_fn_attach },
{ MSG_CREATE, server_msg_fn_create },
{ MSG_INPUT, server_msg_fn_input },
@@ -68,7 +68,7 @@ int
server_msg_dispatch(struct client *c)
{
struct hdr hdr;
- struct server_msg *msg;
+ const struct server_msg *msg;
u_int i;
int n;
diff --git a/tmux.c b/tmux.c
index 2e62d5a1..7219a298 100644
--- a/tmux.c
+++ b/tmux.c
@@ -1,4 +1,4 @@
-/* $Id: tmux.c,v 1.19 2007-10-02 17:35:00 nicm Exp $ */
+/* $Id: tmux.c,v 1.20 2007-10-03 09:17:00 nicm Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
@@ -44,7 +44,7 @@ struct op {
const char *alias;
int (*fn)(char *, int, char **);
};
-struct op op_table[] = {
+const struct op op_table[] = {
{ "attach", NULL, op_attach },
{ "list-sessions", "ls", op_list_sessions },
{ "list-windows", "lsw", op_list_windows },
@@ -158,7 +158,7 @@ sigreset(void)
int
main(int argc, char **argv)
{
- struct op *op, *found;
+ const struct op *op, *found;
char *path;
int opt;
u_int i;