mirror of
https://github.com/tmux/tmux.git
synced 2024-11-17 18:08:51 +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
6fe25a08d7
commit
d956ed0760
4
grid.c
4
grid.c
@ -1,4 +1,4 @@
|
||||
/* $Id: grid.c,v 1.24 2009-07-14 06:40:33 nicm Exp $ */
|
||||
/* $Id: grid.c,v 1.25 2009-07-16 07:35:35 nicm Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2008 Nicholas Marriott <nicm@users.sourceforge.net>
|
||||
@ -554,7 +554,7 @@ grid_duplicate_lines(
|
||||
if (src->usize[sy] == 0)
|
||||
dst->udata[dy] = NULL;
|
||||
else {
|
||||
dst->udata[sy] = xcalloc(
|
||||
dst->udata[dy] = xcalloc(
|
||||
src->usize[sy], sizeof **dst->udata);
|
||||
memcpy(dst->udata[dy], src->udata[sy],
|
||||
src->usize[sy] * (sizeof **dst->udata));
|
||||
|
Loading…
Reference in New Issue
Block a user