summaryrefslogtreecommitdiff
path: root/usr.bin
diff options
context:
space:
mode:
authorNicholas Marriott <nicm@cvs.openbsd.org>2020-03-16 09:12:45 +0000
committerNicholas Marriott <nicm@cvs.openbsd.org>2020-03-16 09:12:45 +0000
commitdcb4373f5fc85242f2c5a8fdd8993d6bb2198a5a (patch)
tree96374725d18de41ef51578681e6680cd00dc605b /usr.bin
parent52c14a7072c4608fdc9336acebdc01f6e6257236 (diff)
Terminate the output buffer for control mode output - it is now used as
a string. GitHub issue 2114.
Diffstat (limited to 'usr.bin')
-rw-r--r--usr.bin/tmux/control-notify.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/usr.bin/tmux/control-notify.c b/usr.bin/tmux/control-notify.c
index 2e8b50f9c32..aeb6ad9adb4 100644
--- a/usr.bin/tmux/control-notify.c
+++ b/usr.bin/tmux/control-notify.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: control-notify.c,v 1.25 2019/12/12 11:39:56 nicm Exp $ */
+/* $OpenBSD: control-notify.c,v 1.26 2020/03/16 09:12:44 nicm Exp $ */
/*
* Copyright (c) 2012 Nicholas Marriott <nicholas.marriott@gmail.com>
@@ -54,6 +54,7 @@ control_notify_input(struct client *c, struct window_pane *wp,
else
evbuffer_add_printf(message, "%c", buf[i]);
}
+ evbuffer_add(message, "", 1);
control_write(c, "%s", EVBUFFER_DATA(message));
evbuffer_free(message);
}