From 2c73593fcdf97352d715817b59c577cfae212b2c Mon Sep 17 00:00:00 2001 From: Alug Date: Thu, 25 Sep 2025 03:43:28 +0200 Subject: [PATCH] ensure "rawconv" is nulled before reuse otherwise there might be some leftovers from earlier calls --- src/r_patchrotation.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/r_patchrotation.c b/src/r_patchrotation.c index bea963342..15a54d88e 100644 --- a/src/r_patchrotation.c +++ b/src/r_patchrotation.c @@ -241,6 +241,10 @@ void RotatedPatch_DoRotation(rotsprite_t *rotsprite, patch_t *patch, INT32 angle rawconv = Z_Calloc(size * sizeof(UINT16), PU_STATIC, NULL); conv_capacity = size; } + else + { + memset(rawconv, 0, conv_capacity * sizeof(UINT16)); + } src = &rawdst[(miny * newwidth) + minx]; dest = rawconv;