mirror of
https://codeberg.org/dnkl/foot.git
synced 2026-02-05 04:06:08 -05:00
config: check for FcNameUnparse() failure
This commit is contained in:
parent
ba7ecc4669
commit
736328ab6b
1 changed files with 5 additions and 0 deletions
5
config.c
5
config.c
|
|
@ -3729,6 +3729,11 @@ config_font_parse(const char *pattern, struct config_font *font)
|
||||||
|
|
||||||
LOG_DBG("%s: pt-size=%.2f, px-size=%d", stripped_pattern, pt_size, px_size);
|
LOG_DBG("%s: pt-size=%.2f, px-size=%d", stripped_pattern, pt_size, px_size);
|
||||||
|
|
||||||
|
if (stripped_pattern == NULL) {
|
||||||
|
LOG_ERR("failed to convert font pattern to string");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
*font = (struct config_font){
|
*font = (struct config_font){
|
||||||
.pattern = stripped_pattern,
|
.pattern = stripped_pattern,
|
||||||
.pt_size = pt_size,
|
.pt_size = pt_size,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue