[directwrite] Simplify delete
Fixes https://github.com/harfbuzz/harfbuzz/issues/3981
This commit is contained in:
parent
7b0f9abc89
commit
326db329f8
|
@ -251,15 +251,11 @@ _hb_directwrite_shaper_face_data_destroy (hb_directwrite_face_data_t *data)
|
||||||
data->dwriteFactory->UnregisterFontFileLoader (data->fontFileLoader);
|
data->dwriteFactory->UnregisterFontFileLoader (data->fontFileLoader);
|
||||||
data->dwriteFactory->Release ();
|
data->dwriteFactory->Release ();
|
||||||
}
|
}
|
||||||
if (data->fontFileLoader)
|
|
||||||
delete data->fontFileLoader;
|
delete data->fontFileLoader;
|
||||||
if (data->fontFileStream)
|
|
||||||
delete data->fontFileStream;
|
delete data->fontFileStream;
|
||||||
if (data->faceBlob)
|
|
||||||
hb_blob_destroy (data->faceBlob);
|
hb_blob_destroy (data->faceBlob);
|
||||||
if (data->dwrite_dll)
|
if (data->dwrite_dll)
|
||||||
FreeLibrary (data->dwrite_dll);
|
FreeLibrary (data->dwrite_dll);
|
||||||
if (data)
|
|
||||||
delete data;
|
delete data;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue