raster pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=e2887ec2aaddb3176be180fc0bfc050508559773
commit e2887ec2aaddb3176be180fc0bfc050508559773 Author: Carsten Haitzler (Rasterman) <[email protected]> Date: Thu Dec 19 10:33:37 2019 +0000 evas textblock - use snprintf to limit buffer and have buffer big enough the buffer wasn't big enough for all possible content anyway and it didn't use snprintf, so large values of i could overflow... pointed to by warning. fix that warning. --- src/lib/evas/canvas/evas_object_textblock.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/lib/evas/canvas/evas_object_textblock.c b/src/lib/evas/canvas/evas_object_textblock.c index 3af3fb2897..d7c629705e 100644 --- a/src/lib/evas/canvas/evas_object_textblock.c +++ b/src/lib/evas/canvas/evas_object_textblock.c @@ -15631,9 +15631,9 @@ void fit_style_update(Evas_Object *object, int i_font_size, Eina_Bool disable_el char * fit_style = fc->fit_style; if (i_font_size >= 0) { - char font_size[0xF] = {0}; + char font_size[24]; char *pfont = font_size; - sprintf(font_size, "font_size=%i ", i_font_size); + snprintf(font_size, sizeof(font_size), "font_size=%i ", i_font_size); while (*pfont) { *fit_style = *pfont; --
