grid: reflow: ‘amount’ has already been added to ‘from’

This commit is contained in:
Daniel Eklöf 2021-06-02 19:30:01 +02:00
parent cb83d60089
commit 3292bb5b8e
No known key found for this signature in database
GPG key ID: 5BBD4992C116573F

2
grid.c
View file

@ -667,7 +667,7 @@ grid_resize_and_reflow(
if (unlikely(spacers > 0)) {
xassert(new_col_idx + spacers == new_cols);
const struct cell *cell = &old_row->cells[from + amount - 1];
const struct cell *cell = &old_row->cells[from - 1];
for (int i = 0; i < spacers; i++, new_col_idx++) {
new_row->cells[new_col_idx].wc = CELL_SPACER;