Module: wine Branch: master Commit: eae84e7ddecf838f8670f446aee05abe88792ac4 URL: http://source.winehq.org/git/wine.git/?a=commit;h=eae84e7ddecf838f8670f446ae...
Author: Nikolay Sivov nsivov@codeweavers.com Date: Thu Jan 21 21:58:41 2016 +0300
dwrite: Return earlier from GetKerningPairAdjustments() when pair kerning is not supported.
Signed-off-by: Nikolay Sivov nsivov@codeweavers.com Signed-off-by: Alexandre Julliard julliard@winehq.org
---
dlls/dwrite/font.c | 5 +++++ 1 file changed, 5 insertions(+)
diff --git a/dlls/dwrite/font.c b/dlls/dwrite/font.c index dab7322..2ff3b8c 100644 --- a/dlls/dwrite/font.c +++ b/dlls/dwrite/font.c @@ -880,6 +880,11 @@ static HRESULT WINAPI dwritefontface1_GetKerningPairAdjustments(IDWriteFontFace2 return E_INVALIDARG; }
+ if (!This->has_kerning_pairs) { + memset(adjustments, 0, count*sizeof(INT32)); + return S_OK; + } + for (i = 0; i < count-1; i++) adjustments[i] = freetype_get_kerning_pair_adjustment(iface, indices[i], indices[i+1]); adjustments[count-1] = 0;