From b96a261a3538b98614a798fb6bc2093319a8054f Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Wed, 14 Jun 2023 08:03:47 +0530 Subject: [PATCH] ... --- kitty/line-buf.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/kitty/line-buf.c b/kitty/line-buf.c index 659114ce8..91bd24af9 100644 --- a/kitty/line-buf.c +++ b/kitty/line-buf.c @@ -538,7 +538,8 @@ copy_old(LineBuf *self, PyObject *y) { if (!PyObject_TypeCheck(y, &LineBuf_Type)) { PyErr_SetString(PyExc_TypeError, "Not a LineBuf object"); return NULL; } LineBuf *other = (LineBuf*)y; if (other->xnum != self->xnum) { PyErr_SetString(PyExc_ValueError, "LineBuf has a different number of columns"); return NULL; } - Line sl = {{0}}, ol = {{0}}; + Line sl, ol; + zero_at_ptr(&sl); zero_at_ptr(&ol); sl.xnum = self->xnum; ol.xnum = other->xnum; for (index_type i = 0; i < MIN(self->ynum, other->ynum); i++) {