diff options
author | William Wilgus <me.theuser@yahoo.com> | 2018-12-06 01:23:33 -0600 |
---|---|---|
committer | William Wilgus <me.theuser@yahoo.com> | 2019-07-10 06:31:22 +0200 |
commit | 3ec002e12160957265e5980cbd54a028ba19319b (patch) | |
tree | a439d9f3e44101b3c33f5b90d52ea709500446f8 /apps/gui/color_picker.c | |
parent | a980c0b3e51466d041f1a05a1bd2e7afd6a8efe8 (diff) | |
download | rockbox-3ec002e12160957265e5980cbd54a028ba19319b.tar.gz rockbox-3ec002e12160957265e5980cbd54a028ba19319b.zip |
Fix truncation warning color_picker.c->draw_screen
Change-Id: I72f16163684aba6c9c3fcf4ade6f2906d80b3899
Diffstat (limited to 'apps/gui/color_picker.c')
-rw-r--r-- | apps/gui/color_picker.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/apps/gui/color_picker.c b/apps/gui/color_picker.c index a66b131560..03096e5589 100644 --- a/apps/gui/color_picker.c +++ b/apps/gui/color_picker.c | |||
@@ -259,9 +259,9 @@ static void draw_screen(struct screen *display, char *title, | |||
259 | display->putsxy(text_x, text_top, buf); | 259 | display->putsxy(text_x, text_top, buf); |
260 | /* Draw color value */ | 260 | /* Draw color value */ |
261 | if (display->depth >= 24) | 261 | if (display->depth >= 24) |
262 | snprintf(buf, 4, "%03d", rgb->rgb_val[i]); | 262 | snprintf(buf, 4, "%03d", rgb->rgb_val[i] & 0xFF); |
263 | else | 263 | else |
264 | snprintf(buf, 3, "%02d", rgb->rgb_val[i]); | 264 | snprintf(buf, 3, "%02d", rgb->rgb_val[i] & 0x3F); |
265 | vp.flags |= VP_FLAG_ALIGN_RIGHT; | 265 | vp.flags |= VP_FLAG_ALIGN_RIGHT; |
266 | display->putsxy(text_x, text_top, buf); | 266 | display->putsxy(text_x, text_top, buf); |
267 | 267 | ||