=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/tmux/control.c,v retrieving revision 1.28 retrieving revision 1.29 diff -c -r1.28 -r1.29 *** src/usr.bin/tmux/control.c 2020/04/13 14:46:04 1.28 --- src/usr.bin/tmux/control.c 2020/04/13 15:55:51 1.29 *************** *** 1,4 **** ! /* $OpenBSD: control.c,v 1.28 2020/04/13 14:46:04 nicm Exp $ */ /* * Copyright (c) 2012 Nicholas Marriott --- 1,4 ---- ! /* $OpenBSD: control.c,v 1.29 2020/04/13 15:55:51 nicm Exp $ */ /* * Copyright (c) 2012 Nicholas Marriott *************** *** 60,65 **** --- 60,66 ---- { char *line; struct cmdq_item *item; + struct cmdq_state *state; struct cmd_parse_result *pr; if (closed || error != 0) *************** *** 85,93 **** cmdq_append(c, item); break; case CMD_PARSE_SUCCESS: ! item = cmdq_get_command(pr->cmdlist, NULL, NULL, ! CMDQ_STATE_CONTROL); cmdq_append(c, item); cmd_list_free(pr->cmdlist); break; } --- 86,95 ---- cmdq_append(c, item); break; case CMD_PARSE_SUCCESS: ! state = cmdq_new_state(NULL, NULL, CMDQ_STATE_CONTROL); ! item = cmdq_get_command(pr->cmdlist, state); cmdq_append(c, item); + cmdq_free_state(state); cmd_list_free(pr->cmdlist); break; }