Commit 54e3e0a6a86e3cc5328202696b10309c19ab99e5

sammy 2008-05-01T18:46:22

* Proper FTFace member initialisation to prevent destructor-time crashes.

diff --git a/src/FTFace.cpp b/src/FTFace.cpp
index a87194f..8a3cf6d 100644
--- a/src/FTFace.cpp
+++ b/src/FTFace.cpp
@@ -31,8 +31,7 @@
 #include FT_TRUETYPE_TABLES_H
 
 FTFace::FTFace(const char* fontFilePath, bool precomputeKerning)
-:   ftFace(0),
-    numGlyphs(0),
+:   numGlyphs(0),
     fontEncodingList(0),
     kerningCache(0),
     err(0)
@@ -62,6 +61,8 @@ FTFace::FTFace(const char* fontFilePath, bool precomputeKerning)
 FTFace::FTFace(const unsigned char *pBufferBytes, size_t bufferSizeInBytes,
                bool precomputeKerning)
 :   numGlyphs(0),
+    fontEncodingList(0),
+    kerningCache(0),
     err(0)
 {
     const FT_Long DEFAULT_FACE_INDEX = 0;