Fix a possible crash in R_RenderMaskedSegRange

https://git.do.srb2.org/STJr/SRB2/-/commit/55b4458001b2ffe76774ff07a11b56ebf1f70de9
This commit is contained in:
alufolie91 committed 2023-09-04 15:30:21 +02:00
1 parent e79bf24bcd
commit 90cc5a6cb0
1 file changed
+3
+3
View File
@@ -1769,6 +1769,9 @@ void R_StoreWallRange(INT32 start, INT32 stop)
while (need > maxopenings);
openings = Z_Realloc(openings, maxopenings * sizeof (*openings), PU_STATIC, NULL);
lastopening = openings + pos;
if (oldopenings == NULL)
return;
// borrowed fix from *cough* zdoom *cough*
// [RH] We also need to adjust the openings pointers that