From cad78e04ab96f8c71b7da96849934dc64d83d8f0 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Tue, 25 Nov 2014 09:19:18 -0500 Subject: [PATCH] text: declare loop variables in loop headers --- source/text.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/source/text.cpp b/source/text.cpp index 7fa7cc6..f3e13c6 100644 --- a/source/text.cpp +++ b/source/text.cpp @@ -35,10 +35,9 @@ int drawCharacter(u8* fb, font_s* font, char c, s16 x, s16 y, u16 w, u16 h) const u8 g = font->color[1]; const u8 b = font->color[2]; - int i, j; - for (i = 0; i < cd->w; i++) { + for (int i = 0; i < cd->w; i++) { charData += cyo; - for(j = 0; j < ch; j++) { + for (int j = 0; j < ch; j++) { u8 v = *(charData++); if (v) { fb[0] = (fb[0] * (0xFF - v) + (b * v)) >> 8;