aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicholas Marriott <nicm@openbsd.org>2012-09-03 10:02:39 +0000
committerNicholas Marriott <nicm@openbsd.org>2012-09-03 10:02:39 +0000
commitc96a2a3c9e7a0c460c668f65712a7beac07953bf (patch)
treee25255d1b7867ca3c7f3f03ac8b5a4541956ab9a
parent7263fa36eb3d4488b89d01837dc4bd533e6f061a (diff)
downloadrtmux-c96a2a3c9e7a0c460c668f65712a7beac07953bf.tar.gz
rtmux-c96a2a3c9e7a0c460c668f65712a7beac07953bf.tar.bz2
rtmux-c96a2a3c9e7a0c460c668f65712a7beac07953bf.zip
Rename variables to something a but more understandable.
-rw-r--r--cmd-choose-list.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/cmd-choose-list.c b/cmd-choose-list.c
index 8b605d08..15c644ec 100644
--- a/cmd-choose-list.c
+++ b/cmd-choose-list.c
@@ -51,8 +51,8 @@ cmd_choose_list_exec(struct cmd *self, struct cmd_ctx *ctx)
{
struct args *args = self->args;
struct winlink *wl;
- const char *lists;
- char *template, *list, *copy, *lists1;
+ const char *list1;
+ char *template, *item, *copy, *list;
u_int idx;
if (ctx->curclient == NULL) {
@@ -60,7 +60,7 @@ cmd_choose_list_exec(struct cmd *self, struct cmd_ctx *ctx)
return (CMD_RETURN_ERROR);
}
- if ((lists = args_get(args, 'l')) == NULL)
+ if ((list1 = args_get(args, 'l')) == NULL)
return (CMD_RETURN_ERROR);
if ((wl = cmd_find_window(ctx, args_get(args, 't'), NULL)) == NULL)
@@ -74,13 +74,13 @@ cmd_choose_list_exec(struct cmd *self, struct cmd_ctx *ctx)
else
template = xstrdup(CMD_CHOOSE_LIST_DEFAULT_TEMPLATE);
- copy = lists1 = xstrdup(lists);
+ copy = list = xstrdup(list1);
idx = 0;
- while ((list = strsep(&lists1, ",")) != NULL)
+ while ((item = strsep(&list, ",")) != NULL)
{
- if (*list == '\0') /* no empty entries */
+ if (*item == '\0') /* no empty entries */
continue;
- window_choose_add_item(wl->window->active, ctx, wl, list,
+ window_choose_add_item(wl->window->active, ctx, wl, item,
template, idx);
idx++;
}