From c20eb0c0ae3347c768894a6355adfd7ebae6f2f3 Mon Sep 17 00:00:00 2001 From: nicm Date: Mon, 13 Apr 2020 08:26:27 +0000 Subject: Make struct cmd local to cmd.c and move it out of tmux.h. --- cmd-show-environment.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'cmd-show-environment.c') diff --git a/cmd-show-environment.c b/cmd-show-environment.c index 0d2f7dd9..be6209dd 100644 --- a/cmd-show-environment.c +++ b/cmd-show-environment.c @@ -69,7 +69,7 @@ static void cmd_show_environment_print(struct cmd *self, struct cmdq_item *item, struct environ_entry *envent) { - struct args *args = self->args; + struct args *args = cmd_get_args(self); char *escaped; if (!args_has(args, 'h') && (envent->flags & ENVIRON_HIDDEN)) @@ -77,7 +77,7 @@ cmd_show_environment_print(struct cmd *self, struct cmdq_item *item, if (args_has(args, 'h') && (~envent->flags & ENVIRON_HIDDEN)) return; - if (!args_has(self->args, 's')) { + if (!args_has(args, 's')) { if (envent->value != NULL) cmdq_print(item, "%s=%s", envent->name, envent->value); else @@ -97,7 +97,7 @@ cmd_show_environment_print(struct cmd *self, struct cmdq_item *item, static enum cmd_retval cmd_show_environment_exec(struct cmd *self, struct cmdq_item *item) { - struct args *args = self->args; + struct args *args = cmd_get_args(self); struct environ *env; struct environ_entry *envent; const char *target; @@ -109,7 +109,7 @@ cmd_show_environment_exec(struct cmd *self, struct cmdq_item *item) } } - if (args_has(self->args, 'g')) + if (args_has(args, 'g')) env = global_environ; else { if (item->target.s == NULL) { -- cgit v1.2.3