diff options
-rw-r--r-- | src/renderer/tr_font.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/renderer/tr_font.c b/src/renderer/tr_font.c index 25954b66..02ccb80f 100644 --- a/src/renderer/tr_font.c +++ b/src/renderer/tr_font.c @@ -398,8 +398,8 @@ void RE_RegisterFont(const char *fontName, int pointSize, fontInfo_t *font) { font->glyphs[i].s2 = readFloat(); font->glyphs[i].t2 = readFloat(); font->glyphs[i].glyph = readInt(); - Com_Memcpy(font->glyphs[i].shaderName, &fdFile[fdOffset], 32); - fdOffset += 32; + Q_strncpyz(font->glyphs[i].shaderName, (const char *)&fdFile[fdOffset], sizeof(font->glyphs[i].shaderName)); + fdOffset += sizeof(font->glyphs[i].shaderName); } font->glyphScale = readFloat(); Com_Memcpy(font->name, &fdFile[fdOffset], MAX_QPATH); |