Bug 1638331 - Expand the conditions for crashing in GetDWriteSystemFonts. r=jfkthame

We're not seeing any crashes so let's look for a null systemFonts
as well.

Differential Revision: https://phabricator.services.mozilla.com/D75546
This commit is contained in:
Jeff Muizelaar 2020-05-15 17:00:03 +00:00
Родитель 3b07e6dc71
Коммит 881b06790a
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -933,7 +933,7 @@ RefPtr<IDWriteFontCollection> Factory::GetDWriteSystemFonts(bool aUpdate) {
RefPtr<IDWriteFontCollection> systemFonts;
HRESULT hr =
mDWriteFactory->GetSystemFontCollection(getter_AddRefs(systemFonts));
if (FAILED(hr)) {
if (FAILED(hr) || !systemFonts) {
// only crash some of the time so those experiencing this problem
// don't stop using Firefox
if ((rand() & 0x3f) == 0) {