diff options
author | Werner Lemberg <wl@gnu.org> | 2023-02-01 12:01:58 +0100 |
---|---|---|
committer | Werner Lemberg <wl@gnu.org> | 2023-02-01 12:01:58 +0100 |
commit | 9508811a3a5bc9a8f93da9edabb1521713a9a906 (patch) | |
tree | 326205ca13b1c4317179258570ea1654a00dcd2f | |
parent | aec87c0955b0f6b7db6dc3c7e6200823b8124a3c (diff) | |
download | freetype2-9508811a3a5bc9a8f93da9edabb1521713a9a906.tar.gz |
* src/truetype/ttgxvar.c (tt_var_get_item_delta): Check `face->blend`.
Reported as
https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=55581
-rw-r--r-- | src/truetype/ttgxvar.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/truetype/ttgxvar.c b/src/truetype/ttgxvar.c index ba538683c..699acb682 100644 --- a/src/truetype/ttgxvar.c +++ b/src/truetype/ttgxvar.c @@ -1004,16 +1004,16 @@ GX_ItemVarData varData; FT_ItemVarDelta* deltaSet; - FT_UInt master, j; - FT_Fixed* scalars; - FT_ItemVarDelta returnValue; + FT_UInt master, j; + FT_Fixed* scalars; + FT_ItemVarDelta returnValue; - if ( !face->blend->normalizedcoords ) + if ( !face->blend || !face->blend->normalizedcoords ) return 0; - /* OpenType 1.8.4+: No variation data for this item - * as indices have special value 0xFFFF. */ + /* OpenType 1.8.4+: No variation data for this item */ + /* as indices have special value 0xFFFF. */ if ( outerIndex == 0xFFFF && innerIndex == 0xFFFF ) return 0; |