summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorFlorent Rougon <f.rougon@free.fr>2017-06-07 01:34:51 +0200
committerAkira TAGOH <akira@tagoh.org>2017-06-09 15:52:23 +0900
commit209619b1a63f415320c8d379efc0525273c7b575 (patch)
tree524f2b75e176dfa4adb2d6ade609fe0bc57b66c6 /src
parent4970c7e810fec29b5ad40a595850288f14f48e37 (diff)
Fix erroneous test on language id in FcLangSetPromote()
FcLangSetIndex() indicates "not found" with a non-negative return value. Return value 0 doesn't imply "not found", it rather means "language found at index 0 in fcLangCharSets".
Diffstat (limited to 'src')
-rw-r--r--src/fclang.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/fclang.c b/src/fclang.c
index 19f3ddd4..dbbe7216 100644
--- a/src/fclang.c
+++ b/src/fclang.c
@@ -732,7 +732,7 @@ FcLangSetPromote (const FcChar8 *lang, FcValuePromotionBuffer *vbuf)
if (lang)
{
id = FcLangSetIndex (lang);
- if (id > 0)
+ if (id >= 0)
{
FcLangSetBitSet (&buf->ls, id);
}