From 083e03785a1d2441f84e72c3adbdee95c2230b33 Mon Sep 17 00:00:00 2001 From: rodri Date: Tue, 19 Dec 2023 12:11:39 +0000 Subject: initialize the zbuflk to zero. --- main.c | 1 + 1 file changed, 1 insertion(+) diff --git a/main.c b/main.c index b01d2cf..49dfc43 100644 --- a/main.c +++ b/main.c @@ -299,6 +299,7 @@ mkfb(Rectangle r) fb->zb = eallocmemimage(r, RGBA32); fb->zbuf = emalloc(Dx(r)*Dy(r)*sizeof(*fb->zbuf)); memsetd(fb->zbuf, Inf(-1), Dx(r)*Dy(r)); + memset(&fb->zbuflk, 0, sizeof(fb->zbuflk)); fb->nb = eallocmemimage(r, RGBA32); /* XXX DBG */ fb->r = r; return fb; -- cgit v1.2.3