diff --git a/src/x11/colour.cpp b/src/x11/colour.cpp index 467d3f45a0..7f9e2878c1 100644 --- a/src/x11/colour.cpp +++ b/src/x11/colour.cpp @@ -172,7 +172,8 @@ wxGDIRefData *wxColour::CloneGDIRefData(const wxGDIRefData *data) const void wxColour::InitRGBA(unsigned char red, unsigned char green, unsigned char blue, unsigned char WXUNUSED(alpha)) { - AllocExclusive(); + UnRef(); + m_refData = new wxColourRefData(); #if wxUSE_NANOX M_COLDATA->m_color.red = ((unsigned short)red) ;