aboutsummaryrefslogtreecommitdiff
path: root/cmd-list.c
diff options
context:
space:
mode:
authorTiago Cunha <tcunha@gmx.com>2012-08-12 19:23:01 +0000
committerTiago Cunha <tcunha@gmx.com>2012-08-12 19:23:01 +0000
commitc8849ac990af34eef6b3516c392d1796b4fbeba3 (patch)
tree3cc0ecd6be9a992c44857d4d986060fb40978a7d /cmd-list.c
parent44307712edd30911286fb350788b64ba77dc3a20 (diff)
downloadrtmux-c8849ac990af34eef6b3516c392d1796b4fbeba3.tar.gz
rtmux-c8849ac990af34eef6b3516c392d1796b4fbeba3.tar.bz2
rtmux-c8849ac990af34eef6b3516c392d1796b4fbeba3.zip
Sync OpenBSD patchset 1153:
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 0557000e..1717ec3b 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);
}