summaryrefslogtreecommitdiffstats
path: root/cmd-list.c
diff options
context:
space:
mode:
authorNicholas Marriott <nicm@openbsd.org>2012-07-13 06:27:41 +0000
committerNicholas Marriott <nicm@openbsd.org>2012-07-13 06:27:41 +0000
commit5385a9bb347ae703fdc44eb59c71d70e61fbf95e (patch)
tree8b62f04660a8c99b8315117072d6a06384c6dbdd /cmd-list.c
parent35a8a61254a190d2c4ec52f0525993ab1594bc44 (diff)
Add a queue of notifys and a way to turn them off and on (we do not want
notifys to happen during some commands). Based on code from George Nachman.
Diffstat (limited to 'cmd-list.c')
-rw-r--r--cmd-list.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/cmd-list.c b/cmd-list.c
index 80d1ade3..2cf66a80 100644
--- a/cmd-list.c
+++ b/cmd-list.c
@@ -91,6 +91,8 @@ cmd_list_exec(struct cmd_list *cmdlist, struct cmd_ctx *ctx)
if (c != NULL && c->session != NULL)
guards = c->flags & CLIENT_CONTROL;
+ notify_disable();
+
retval = 0;
TAILQ_FOREACH(cmd, &cmdlist->list, qentry) {
if (guards)
@@ -128,6 +130,8 @@ cmd_list_exec(struct cmd_list *cmdlist, struct cmd_ctx *ctx)
break;
}
}
+
+ notify_enable();
return (retval);
}