Solve warnings

This commit is contained in:
Gabor
2017-05-10 16:11:20 +02:00
parent 3f0323192c
commit 20f4685541
12 changed files with 63 additions and 39 deletions

View File

@@ -283,7 +283,7 @@ void lv_draw_label(const area_t * cords_p,const area_t * mask_p, const lv_style_
if(txt[i] == ' ') {
/*Get the parameter*/
if(i - par_start == LABEL_RECOLOR_PAR_LENGTH) {
char buf[LABEL_RECOLOR_PAR_LENGTH];
char buf[LABEL_RECOLOR_PAR_LENGTH + 1];
memcpy(buf, &txt[par_start], LABEL_RECOLOR_PAR_LENGTH);
buf[LABEL_RECOLOR_PAR_LENGTH] = '\0';
int r,g,b;