diff --git a/src/ccstruct/fontinfo.cpp b/src/ccstruct/fontinfo.cpp index 493d42d7ef..bef879bb79 100644 --- a/src/ccstruct/fontinfo.cpp +++ b/src/ccstruct/fontinfo.cpp @@ -2,7 +2,6 @@ // File: fontinfo.cpp // Description: Font information classes abstracted from intproto.h/cpp. // Author: rays@google.com (Ray Smith) -// Created: Wed May 18 10:39:01 PDT 2011 // // (C) Copyright 2011, Google Inc. // Licensed under the Apache License, Version 2.0 (the "License"); @@ -140,8 +139,10 @@ void FontInfoDeleteCallback(FontInfo f) { if (f.spacing_vec != nullptr) { f.spacing_vec->delete_data_pointers(); delete f.spacing_vec; + f.spacing_vec = nullptr; } delete[] f.name; + f.name = nullptr; } void FontSetDeleteCallback(FontSet fs) { delete[] fs.configs;