X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/aad6765cbd8916ddeb0362b091663138c2e74df3..7f8c0d74d7025b6c677fbd88890ea10d302ef3d5:/src/x11/colour.cpp diff --git a/src/x11/colour.cpp b/src/x11/colour.cpp index f62111a909..9ce03f2d5b 100644 --- a/src/x11/colour.cpp +++ b/src/x11/colour.cpp @@ -93,8 +93,9 @@ void wxColourRefData::FreeColour() if (!m_colormap) return; #if !wxUSE_NANOX - if ((wxTheApp->m_visualInfo->m_visualType == GrayScale) || - (wxTheApp->m_visualInfo->m_visualType == PseudoColor)) + if ( wxTheApp && + (wxTheApp->m_visualInfo->m_visualType == GrayScale || + wxTheApp->m_visualInfo->m_visualType == PseudoColor) ) { int idx = m_color.pixel; colMapAllocCounter[ idx ] = colMapAllocCounter[ idx ] - 1; @@ -213,7 +214,7 @@ bool wxColour::operator == ( const wxColour& col ) const return (own->red == other->red) && (own->green == other->green) - && (own->blue == other->blue) + && (own->blue == other->blue) ; }