X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/fedad417ce939cbb0ddb519e9777145c76712cb8..05ac7ac5785ef0ddb1bd04585f3c59c5d53089be:/src/mac/palette.cpp diff --git a/src/mac/palette.cpp b/src/mac/palette.cpp index 1c18196135..c847131f40 100644 --- a/src/mac/palette.cpp +++ b/src/mac/palette.cpp @@ -36,7 +36,10 @@ wxPaletteRefData::wxPaletteRefData() wxPaletteRefData::~wxPaletteRefData() { - delete[] m_palette ; + if (m_palette != NULL) { + delete[] m_palette ; + m_palette = NULL; + } } wxPalette::wxPalette()