Commit: 6b283f1168295cf3b88fd29aa09f88feb10c1137
Author: Campbell Barton
Date:   Fri Jan 17 02:13:55 2014 +1100
https://developer.blender.org/rB6b283f1168295cf3b88fd29aa09f88feb10c1137

Fix for BLF using realloc() on guarded-alloced memory

===================================================================

M       source/blender/blenfont/intern/blf_glyph.c

===================================================================

diff --git a/source/blender/blenfont/intern/blf_glyph.c 
b/source/blender/blenfont/intern/blf_glyph.c
index 2a8e912..8a734f9 100644
--- a/source/blender/blenfont/intern/blf_glyph.c
+++ b/source/blender/blenfont/intern/blf_glyph.c
@@ -162,7 +162,7 @@ static void blf_glyph_cache_texture(FontBLF *font, 
GlyphCacheBLF *gc)
 
        if (gc->cur_tex >= gc->ntex) {
                gc->ntex *= 2;
-               gc->textures = (GLuint *)realloc((void *)gc->textures, 
sizeof(GLuint) * gc->ntex);
+               gc->textures = (GLuint *)MEM_reallocN((void *)gc->textures, 
sizeof(GLuint) * gc->ntex);
        }
 
        gc->p2_width = (int)blf_next_p2((unsigned int)((gc->rem_glyphs * 
gc->max_glyph_width) + (gc->pad * 2)));

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to