Warn if no <test> nor <edit> elements in <match>
This corrects an error message being reported at https://bugs.freedesktop.org/show_bug.cgi?id=71085 Bug 71085 - "out of memory" errors on empty match element in fonts.conf and somewhat works as a workaround for https://bugs.freedesktop.org/show_bug.cgi?id=59438 Bug 59438 - Fix <alias> inside <match>
This commit is contained in:
parent
525a135ccf
commit
aa22e6e639
|
@ -2566,6 +2566,11 @@ FcParseMatch (FcConfigParse *parse)
|
|||
}
|
||||
FcVStackPopAndDestroy (parse);
|
||||
}
|
||||
if (!rule)
|
||||
{
|
||||
FcConfigMessage (parse, FcSevereWarning, "No <test> nor <edit> elements in <match>");
|
||||
return;
|
||||
}
|
||||
if (!FcConfigAddRule (parse->config, rule, kind))
|
||||
FcConfigMessage (parse, FcSevereError, "out of memory");
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue