From 3ace4a61d27c8e117ecf59cb9fee9f8c33656871 Mon Sep 17 00:00:00 2001 From: Alibek Omarov Date: Sun, 5 Apr 2026 05:23:46 +0500 Subject: [PATCH] ref: gl: fix harmless NULL pointer dereference in alias model loading code --- ref/gl/gl_alias.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/ref/gl/gl_alias.c b/ref/gl/gl_alias.c index c2ae9e6a..715d92fc 100644 --- a/ref/gl/gl_alias.c +++ b/ref/gl/gl_alias.c @@ -337,7 +337,6 @@ Mod_CreateSkinData static rgbdata_t *Mod_CreateSkinData( model_t *mod, const byte *data, int width, int height ) { static rgbdata_t skin; - char name[MAX_QPATH]; int i; skin.width = width; @@ -363,10 +362,8 @@ static rgbdata_t *Mod_CreateSkinData( model_t *mod, const byte *data, int width, } } - COM_FileBase( mod->name, name, sizeof( name )); - // for alias models only player can have remap textures - if( mod != NULL && !Q_stricmp( name, "player" )) + if( mod != NULL && !Q_stricmp( mod->name, "player" )) { texture_t *tx = NULL; int i, size;