diff options
author | Tiago Cunha <tcunha@gmx.com> | 2009-12-04 22:11:23 +0000 |
---|---|---|
committer | Tiago Cunha <tcunha@gmx.com> | 2009-12-04 22:11:23 +0000 |
commit | 1caa73afb4da381425160cbff68284a4dab1470b (patch) | |
tree | a5fa780cb150af303f72d4ec736fba9316d293a1 /status.c | |
parent | ddb5bb80fa9b24f47a1e5af9d808427d316bcf4a (diff) | |
download | rtmux-1caa73afb4da381425160cbff68284a4dab1470b.tar.gz rtmux-1caa73afb4da381425160cbff68284a4dab1470b.tar.bz2 rtmux-1caa73afb4da381425160cbff68284a4dab1470b.zip |
Sync OpenBSD patchset 580:
Eliminate duplicate code and ease the passage for server-wide options by adding
a -w flag to set-option and show-options and making setw and showw aliases to
set -w and show -w.
Note: setw and showw are still there, but now aliases for set -w and show -w.
Diffstat (limited to 'status.c')
-rw-r--r-- | status.c | 16 |
1 files changed, 8 insertions, 8 deletions
@@ -1,4 +1,4 @@ -/* $Id: status.c,v 1.138 2009-11-28 14:54:12 tcunha Exp $ */ +/* $Id: status.c,v 1.139 2009-12-04 22:11:23 tcunha Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net> @@ -1115,7 +1115,7 @@ char * status_prompt_complete(const char *s) { const struct cmd_entry **cmdent; - const struct set_option_entry *optent; + const struct set_option_entry *entry; ARRAY_DECL(, const char *) list; char *prefix, *s2; u_int i; @@ -1130,13 +1130,13 @@ status_prompt_complete(const char *s) if (strncmp((*cmdent)->name, s, strlen(s)) == 0) ARRAY_ADD(&list, (*cmdent)->name); } - for (optent = set_option_table; optent->name != NULL; optent++) { - if (strncmp(optent->name, s, strlen(s)) == 0) - ARRAY_ADD(&list, optent->name); + for (entry = set_session_option_table; entry->name != NULL; entry++) { + if (strncmp(entry->name, s, strlen(s)) == 0) + ARRAY_ADD(&list, entry->name); } - for (optent = set_window_option_table; optent->name != NULL; optent++) { - if (strncmp(optent->name, s, strlen(s)) == 0) - ARRAY_ADD(&list, optent->name); + for (entry = set_window_option_table; entry->name != NULL; entry++) { + if (strncmp(entry->name, s, strlen(s)) == 0) + ARRAY_ADD(&list, entry->name); } /* If none, bail now. */ |