aboutsummaryrefslogtreecommitdiff
path: root/status.c
diff options
context:
space:
mode:
authorThomas Adam <thomas@xteddy.org>2019-05-28 21:02:28 +0100
committerThomas Adam <thomas@xteddy.org>2019-05-28 21:02:28 +0100
commitc96957583f0ff2e377fcbe08ca1a7d88ab071380 (patch)
treef04e751eedc8787eb837d7aec79ae5d08463f80e /status.c
parente7a530fe4c0f8e0f807daf6a1b80d86c67c93e1b (diff)
parent580cd16f4c3474d7cae867b9b24f01665a268e9d (diff)
downloadrtmux-c96957583f0ff2e377fcbe08ca1a7d88ab071380.tar.gz
rtmux-c96957583f0ff2e377fcbe08ca1a7d88ab071380.tar.bz2
rtmux-c96957583f0ff2e377fcbe08ca1a7d88ab071380.zip
Merge branch 'obsd-master'
Diffstat (limited to 'status.c')
-rw-r--r--status.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/status.c b/status.c
index ce36cc3c..0f96f0d3 100644
--- a/status.c
+++ b/status.c
@@ -348,10 +348,8 @@ status_redraw(struct client *c)
/* Resize the target screen. */
if (screen_size_x(&sl->screen) != width ||
screen_size_y(&sl->screen) != lines) {
- if (screen_size_x(&sl->screen) != width)
- force = 1;
screen_resize(&sl->screen, width, lines, 0);
- changed = 1;
+ changed = force = 1;
}
screen_write_start(&ctx, NULL, &sl->screen);
@@ -865,7 +863,7 @@ status_prompt_paste(struct client *c)
if ((pb = paste_get_top(NULL)) == NULL)
return (0);
bufdata = paste_buffer_data(pb, &bufsize);
- ud = xreallocarray(NULL, bufsize, sizeof *ud);
+ ud = xreallocarray(NULL, bufsize + 1, sizeof *ud);
udp = ud;
for (i = 0; i != bufsize; /* nothing */) {
more = utf8_open(udp, bufdata[i]);