X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/f68e16c5fcf53c411742c8338a290addc5fb4b62..062dfc9a96dc9e796c53544f41ff92dc47f26e82:/src/html/winpars.cpp?ds=inline diff --git a/src/html/winpars.cpp b/src/html/winpars.cpp index 9deb4545c0..916c43a989 100644 --- a/src/html/winpars.cpp +++ b/src/html/winpars.cpp @@ -606,8 +606,7 @@ wxFont* wxHtmlWinParser::CreateCurrentFont() #endif )) { - delete *fontptr; - *fontptr = NULL; + wxDELETE(*fontptr); } if (*fontptr == NULL) @@ -669,11 +668,7 @@ void wxHtmlWinParser::SetInputEncoding(wxFontEncoding enc) m_nbsp = 0; m_InputEnc = m_OutputEnc = wxFONTENCODING_DEFAULT; - if (m_EncConv) - { - delete m_EncConv; - m_EncConv = NULL; - } + wxDELETE(m_EncConv); if (enc == wxFONTENCODING_DEFAULT) return; @@ -738,8 +733,7 @@ void wxHtmlWinParser::SetInputEncoding(wxFontEncoding enc) wxLogError(_("Failed to display HTML document in %s encoding"), wxFontMapper::GetEncodingName(enc).c_str()); m_InputEnc = m_OutputEnc = wxFONTENCODING_DEFAULT; - delete m_EncConv; - m_EncConv = NULL; + wxDELETE(m_EncConv); } } #endif