summaryrefslogtreecommitdiffstats
path: root/notify.c
diff options
context:
space:
mode:
authorThomas Adam <thomas@xteddy.org>2020-04-13 14:01:45 +0100
committerThomas Adam <thomas@xteddy.org>2020-04-13 14:01:45 +0100
commit8f2b5d714a9f854c9583cab8bae70a2c7323fa00 (patch)
tree4e887ff4a1fcb3703fb0a1fcaa751183cff24c12 /notify.c
parentb117c3b81217a11946ac784cfbe2ef1f3725b207 (diff)
parent04cdd035250b93b728678d515b69690653dced4e (diff)
Merge branch 'obsd-master'
Diffstat (limited to 'notify.c')
-rw-r--r--notify.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/notify.c b/notify.c
index 703be79d..e43978c8 100644
--- a/notify.c
+++ b/notify.c
@@ -188,17 +188,18 @@ notify_add(const char *name, struct cmd_find_state *fs, struct client *c,
void
notify_hook(struct cmdq_item *item, const char *name)
{
- struct notify_entry ne;
+ struct cmd_find_state *target = cmdq_get_target(item);
+ struct notify_entry ne;
memset(&ne, 0, sizeof ne);
ne.name = name;
- cmd_find_copy_state(&ne.fs, &item->target);
+ cmd_find_copy_state(&ne.fs, target);
- ne.client = item->client;
- ne.session = item->target.s;
- ne.window = item->target.w;
- ne.pane = item->target.wp->id;
+ ne.client = cmdq_get_client(item);
+ ne.session = target->s;
+ ne.window = target->w;
+ ne.pane = target->wp->id;
notify_insert_hook(item, &ne);
}