GRAPHICS: Fix freeing invalid pointers in the BDF font destructor

Fixes a crash on exit when using a non default GUI font.
Possibly fixes #10318.
This commit is contained in:
Bastien Bouclet 2017-11-14 06:38:10 +01:00
parent 327dcf98ec
commit 65d0984364

View File

@ -694,6 +694,8 @@ BdfFont *BdfFont::loadFromCache(Common::SeekableReadStream &stream) {
data.bitmaps = bitmaps;
data.advances = advances;
data.boxes = boxes;
data.familyName = nullptr;
data.slant = nullptr;
return new BdfFont(data, DisposeAfterUse::YES);
}