Fix mixed declarations & code

This commit is contained in:
Sally Coolatta 2022-05-01 20:15:52 -04:00
parent 73a35d3280
commit c72f959d5c

View file

@ -162,10 +162,13 @@ static const char *CopyString(huddrawlist_h list, const char* str)
else list->strbuf_capacity *= 2; else list->strbuf_capacity *= 2;
list->strbuf = (char*) Z_ReallocAlign(list->strbuf, sizeof(char) * list->strbuf_capacity, PU_STATIC, NULL, 8); list->strbuf = (char*) Z_ReallocAlign(list->strbuf, sizeof(char) * list->strbuf_capacity, PU_STATIC, NULL, 8);
} }
{
const char *result = (const char *) &list->strbuf[list->strbuf_len]; const char *result = (const char *) &list->strbuf[list->strbuf_len];
strncpy(&list->strbuf[list->strbuf_len], str, lenstr + 1); strncpy(&list->strbuf[list->strbuf_len], str, lenstr + 1);
list->strbuf_len += lenstr + 1; list->strbuf_len += lenstr + 1;
return result; return result;
}
} }
void LUA_HUD_AddDraw( void LUA_HUD_AddDraw(