aboutsummaryrefslogtreecommitdiff
path: root/grid.c
diff options
context:
space:
mode:
authorNicholas Marriott <nicholas.marriott@gmail.com>2021-03-02 12:08:34 +0000
committerNicholas Marriott <nicholas.marriott@gmail.com>2021-03-02 12:08:34 +0000
commitc01251d02388efceca515c47c257e2b5342e3716 (patch)
treeca89407cb43bd2caa40a6854ba49ce1720e892ce /grid.c
parent5c275c2a1a963876d4ac392067e42120417dbf43 (diff)
parent1466b570eedda0423d5a386d2b16b7ff0c0e477c (diff)
downloadrtmux-c01251d02388efceca515c47c257e2b5342e3716.tar.gz
rtmux-c01251d02388efceca515c47c257e2b5342e3716.tar.bz2
rtmux-c01251d02388efceca515c47c257e2b5342e3716.zip
Merge branch 'master' into 3.2-rc
Diffstat (limited to 'grid.c')
-rw-r--r--grid.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/grid.c b/grid.c
index 90e1a0a5..1822f2b5 100644
--- a/grid.c
+++ b/grid.c
@@ -701,7 +701,6 @@ grid_move_lines(struct grid *gd, u_int dy, u_int py, u_int ny, u_int bg)
gd->linedata[py - 1].flags &= ~GRID_LINE_WRAPPED;
}
-
/* Move a group of cells. */
void
grid_move_cells(struct grid *gd, u_int dx, u_int px, u_int py, u_int nx,
@@ -1049,14 +1048,14 @@ grid_duplicate_lines(struct grid *dst, u_int dy, struct grid *src, u_int sy,
srcl->cellsize * sizeof *dstl->celldata);
} else
dstl->celldata = NULL;
-
if (srcl->extdsize != 0) {
dstl->extdsize = srcl->extdsize;
dstl->extddata = xreallocarray(NULL, dstl->extdsize,
sizeof *dstl->extddata);
memcpy(dstl->extddata, srcl->extddata, dstl->extdsize *
sizeof *dstl->extddata);
- }
+ } else
+ dstl->extddata = NULL;
sy++;
dy++;