Do not double delete the test font data stream (flutter/engine#3365)

SkTypeface::MakeFromStream takes ownership of the passed SkStreamAsset*

Fixes https://github.com/flutter/flutter/issues/7657
This commit is contained in:
Jason Simmons
2017-01-26 12:08:18 -08:00
committed by GitHub
parent 7db0cd44c3
commit 29872224ed

View File

@@ -26,7 +26,7 @@ PassRefPtr<FontData> TestFontSelector::getFontData(
return test_font_data_;
}
auto typeface = SkTypeface::MakeFromStream(GetTestFontData().get());
auto typeface = SkTypeface::MakeFromStream(GetTestFontData().release());
FontPlatformData platform_data(typeface, "Ahem", 14.0, false, false,
FontOrientation::Horizontal, false);