mirror of
https://github.com/tmux/tmux.git
synced 2025-04-07 00:28:48 +00:00
Typo in grid_duplicate_lines (sy for dy) causing it to write into the wrong
place when copying UTF-8 data. Found by Dan Colish.
This commit is contained in:
parent
92da443a9e
commit
924bf8477f
2
grid.c
2
grid.c
@ -554,7 +554,7 @@ grid_duplicate_lines(
|
|||||||
if (src->usize[sy] == 0)
|
if (src->usize[sy] == 0)
|
||||||
dst->udata[dy] = NULL;
|
dst->udata[dy] = NULL;
|
||||||
else {
|
else {
|
||||||
dst->udata[sy] = xcalloc(
|
dst->udata[dy] = xcalloc(
|
||||||
src->usize[sy], sizeof **dst->udata);
|
src->usize[sy], sizeof **dst->udata);
|
||||||
memcpy(dst->udata[dy], src->udata[sy],
|
memcpy(dst->udata[dy], src->udata[sy],
|
||||||
src->usize[sy] * (sizeof **dst->udata));
|
src->usize[sy] * (sizeof **dst->udata));
|
||||||
|
Loading…
Reference in New Issue
Block a user