From b15462bc7e30a2bade792269de07c0acd800e27c Mon Sep 17 00:00:00 2001 From: handa Date: Mon, 11 Jul 2005 01:06:58 +0000 Subject: [PATCH] (OTF_check_features): Even if failed in getting features, if all requested features are negative, return 1. --- src/otfopen.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/src/otfopen.c b/src/otfopen.c index abb4636..d2216a0 100644 --- a/src/otfopen.c +++ b/src/otfopen.c @@ -2927,7 +2927,18 @@ OTF_check_features (OTF *otf, int gsubp, int i, j; if (OTF_get_features (otf, gsubp) < 0) - return -1; + { + for (i = 0; i < n_features; i++) + { + OTF_Tag feature = features[i]; + + if (feature == 0) + continue; + if ((((unsigned) feature) & 0x80000000) == 0) + return -1; + } + return 1; + } if (gsubp) { script_list = &otf->gsub->ScriptList; -- 1.7.10.4