opengl32: Fix empty glyph handling.

This commit is contained in:
Akihiro Sagawa 2013-09-20 00:57:50 +09:00 committed by Alexandre Julliard
parent 310a3b1d11
commit 33e05eb6c5

View file

@ -1121,11 +1121,15 @@ static BOOL wglUseFontBitmaps_common( HDC hdc, DWORD first, DWORD count, DWORD l
bitmap = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, size);
gl_bitmap = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, size);
}
if (unicode)
ret = (GetGlyphOutlineW(hdc, glyph, GGO_BITMAP, &gm, size, bitmap, &identity) != GDI_ERROR);
else
ret = (GetGlyphOutlineA(hdc, glyph, GGO_BITMAP, &gm, size, bitmap, &identity) != GDI_ERROR);
if (!ret) break;
if (needed_size != 0) {
if (unicode)
ret = (GetGlyphOutlineW(hdc, glyph, GGO_BITMAP, &gm,
size, bitmap, &identity) != GDI_ERROR);
else
ret = (GetGlyphOutlineA(hdc, glyph, GGO_BITMAP, &gm,
size, bitmap, &identity) != GDI_ERROR);
if (!ret) break;
}
if (TRACE_ON(wgl)) {
unsigned int bitmask;