1
0
forked from drath/libratbag

tools: fix OOB for LED color parsing

Let's not forget about the null-terminator, he feels lonely otherwise.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
Peter Hutterer
2017-05-09 17:59:21 +10:00
committed by bentiss
parent c815654c94
commit eb01399f26

View File

@@ -1560,7 +1560,7 @@ ratbag_cmd_led_set_color(const struct ratbag_cmd *cmd,
struct ratbag_led *led;
struct ratbag_color color;
int rc;
char red[2], green[2], blue[2];
char red[3], green[3], blue[3];
char *p;
if (argc < 1)