diff options
author | Nicholas Marriott <nicm@cvs.openbsd.org> | 2014-03-31 21:41:36 +0000 |
---|---|---|
committer | Nicholas Marriott <nicm@cvs.openbsd.org> | 2014-03-31 21:41:36 +0000 |
commit | 839ebd256a8eeb0d93c0bda8a41c6add71da179b (patch) | |
tree | 84bcbd12f2c9665828ee2868db9fc27495b9df2a /usr.bin/tmux/status.c | |
parent | 8765f5d395c94852042ba6b88499d1c55a43c045 (diff) |
Make message-limit a server option.
Diffstat (limited to 'usr.bin/tmux/status.c')
-rw-r--r-- | usr.bin/tmux/status.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/usr.bin/tmux/status.c b/usr.bin/tmux/status.c index 4ff945da56e..17ab9b4afaa 100644 --- a/usr.bin/tmux/status.c +++ b/usr.bin/tmux/status.c @@ -1,4 +1,4 @@ -/* $OpenBSD: status.c,v 1.110 2014/02/14 13:59:01 nicm Exp $ */ +/* $OpenBSD: status.c,v 1.111 2014/03/31 21:41:35 nicm Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net> @@ -655,7 +655,6 @@ void printflike2 status_message_set(struct client *c, const char *fmt, ...) { struct timeval tv; - struct session *s = c->session; struct message_entry *msg; va_list ap; int delay; @@ -673,10 +672,7 @@ status_message_set(struct client *c, const char *fmt, ...) msg->msg_time = time(NULL); msg->msg = xstrdup(c->message_string); - if (s == NULL) - limit = 0; - else - limit = options_get_number(&s->options, "message-limit"); + limit = options_get_number(&global_options, "message-limit"); if (ARRAY_LENGTH(&c->message_log) > limit) { limit = ARRAY_LENGTH(&c->message_log) - limit; for (i = 0; i < limit; i++) { |