From 16fc63404d5b9256564feb54bcb44f255a6efdda Mon Sep 17 00:00:00 2001 From: Sean Barrett Date: Sun, 8 Nov 2015 01:03:37 -0800 Subject: [PATCH] suppress bogus static analysis warning --- stb_truetype.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/stb_truetype.h b/stb_truetype.h index b57043e..0b1e3b5 100644 --- a/stb_truetype.h +++ b/stb_truetype.h @@ -43,6 +43,7 @@ // Giumo X. Clanjor // Higor Euripedes // Thomas Fields +// Derek Vinyard // // Misc other: // Ryan Gordon @@ -2714,6 +2715,7 @@ static void stbtt__h_prefilter(unsigned char *pixels, int w, int h, int stride_i unsigned char buffer[STBTT_MAX_OVERSAMPLE]; int safe_w = w - kernel_width; int j; + STBTT_memset(buffer, 0, STBTT_MAX_OVERSAMPLE); // suppress bogus warning from VS2013 -analyze for (j=0; j < h; ++j) { int i; unsigned int total; @@ -2775,6 +2777,7 @@ static void stbtt__v_prefilter(unsigned char *pixels, int w, int h, int stride_i unsigned char buffer[STBTT_MAX_OVERSAMPLE]; int safe_h = h - kernel_width; int j; + STBTT_memset(buffer, 0, STBTT_MAX_OVERSAMPLE); // suppress bogus warning from VS2013 -analyze for (j=0; j < w; ++j) { int i; unsigned int total;