diff options
author | Thomas Adam <thomas@xteddy.org> | 2023-09-15 10:01:11 +0100 |
---|---|---|
committer | Thomas Adam <thomas@xteddy.org> | 2023-09-15 10:01:11 +0100 |
commit | 9f9156c0303ad9c50fd44e0561ef0f5bb21a418b (patch) | |
tree | 9f560c0ba4c8fb3eadc1bee672094a6e2d84fc82 /cmd-queue.c | |
parent | c57a09269b2a40bc78cb03febb24acfdaddd7331 (diff) | |
parent | d394293ba59fc932085eb8c01592822a9b1ec1f7 (diff) |
Merge branch 'obsd-master'
Diffstat (limited to 'cmd-queue.c')
-rw-r--r-- | cmd-queue.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/cmd-queue.c b/cmd-queue.c index e5188c54..e188afcd 100644 --- a/cmd-queue.c +++ b/cmd-queue.c @@ -236,8 +236,10 @@ cmdq_link_state(struct cmdq_state *state) /* Make a copy of a state. */ struct cmdq_state * -cmdq_copy_state(struct cmdq_state *state) +cmdq_copy_state(struct cmdq_state *state, struct cmd_find_state *current) { + if (current != NULL) + return (cmdq_new_state(current, &state->event, state->flags)); return (cmdq_new_state(&state->current, &state->event, state->flags)); } |