mirror of
https://github.com/jjsullivan5196/wvkbd.git
synced 2025-03-12 18:32:48 +01:00
fixed malfunctioning theme at random
This commit is contained in:
parent
8106d7606d
commit
e3081fb6e9
2
main.c
2
main.c
@ -797,7 +797,7 @@ set_kbd_colors(uint8_t *bgra, char *hex)
|
||||
// bg, fg, text, high, swipe
|
||||
int length = strlen(hex);
|
||||
if (length == 6 || length == 8) {
|
||||
char subhex[2];
|
||||
char subhex[3] = { 0 };
|
||||
memcpy(subhex, hex, 2);
|
||||
bgra[2] = (int)strtol(subhex, NULL, 16);
|
||||
memcpy(subhex, hex + 2, 2);
|
||||
|
Loading…
x
Reference in New Issue
Block a user