From efb610713fba68f1bc07a424e35c5e113afaa2e4 Mon Sep 17 00:00:00 2001 From: NepDisk Date: Sun, 19 Oct 2025 22:01:02 -0400 Subject: [PATCH] Revert "Add SIGSEGV guard to highlight patch loading." This reverts commit f6b2f4bd236097f7d5f52fb0d545d9388f2c6f7a. --- src/k_hud.c | 38 +++----------------------------------- 1 file changed, 3 insertions(+), 35 deletions(-) diff --git a/src/k_hud.c b/src/k_hud.c index e0b5b3e6c..1345b04fe 100644 --- a/src/k_hud.c +++ b/src/k_hud.c @@ -381,41 +381,9 @@ void K_LoadKartHUDGraphics(void) buffer[7] = '0'+(i+1); HU_UpdatePatch(&kp_facehighlight[i], "%s", buffer); - // Blind-reading the patch causes a SIGSEGV on some machines, so let's try a guard. - patch_t *highlight = kp_facehighlight[i]; - - if ((highlight) && (highlight != NULL)) - { - highlight->pivot.x = highlight->width / 2; - highlight->pivot.y = highlight->height / 2; - highlight->alignflags |= PATCHALIGN_USEPIVOTS; - } - else - { - CONS_Printf("Patch %s is NULL! Attempting to resolve this issue...", buffer); - UINT8 tries = 0; - while ((!highlight) || (highlight == NULL)) - { - tries++; - - HU_UpdatePatch(&kp_facehighlight[i], "%s", buffer); - - highlight = kp_facehighlight[i]; - - if ((highlight) && (highlight != NULL)) - { - highlight->pivot.x = highlight->width / 2; - highlight->pivot.y = highlight->height / 2; - highlight->alignflags |= PATCHALIGN_USEPIVOTS; - } - else if (tries >= YOURTAKINGTOOLONG) - { - I_Error("Game failed to resolve NULL \"%s\" patch after %d tries (i = %d)\n", buffer, tries, i); - break; - } - } - CONS_Printf("Success: resolved patch issue in %d tries!", i); - } + kp_facehighlight[i]->pivot.x = kp_facehighlight[i]->width / 2; + kp_facehighlight[i]->pivot.y = kp_facehighlight[i]->height / 2; + kp_facehighlight[i]->alignflags |= PATCHALIGN_USEPIVOTS; } // Special minimap icons