mirror of
https://codeberg.org/dnkl/foot.git
synced 2026-02-10 04:27:45 -05:00
osc: parse_rgb(): ensure ‘alpha’ has been initialized
This commit is contained in:
parent
1023f9a6e9
commit
8adb52e63a
1 changed files with 1 additions and 1 deletions
2
osc.c
2
osc.c
|
|
@ -395,7 +395,7 @@ parse_rgb(const char *string, uint32_t *color, bool *_have_alpha,
|
|||
uint8_t g = 256 * (rgb[1] / (double)(1 << (4 * digits[1])));
|
||||
uint8_t b = 256 * (rgb[2] / (double)(1 << (4 * digits[2])));
|
||||
|
||||
uint16_t alpha;
|
||||
uint16_t alpha = 0xffff;
|
||||
if (have_alpha)
|
||||
alpha = 65536 * (rgb[3] / (double)(1 << (4 * digits[3])));
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue