g_displayDC = new MGLDisplayDC(mode, 1, refresh);
if ( !g_displayDC->isValid() )
{
- delete g_displayDC;
- g_displayDC = NULL;
+ wxDELETE(g_displayDC);
return false;
}
MGL_wmDestroy(g_winMng);
g_winMng = NULL;
}
- if ( g_displayDC )
- {
- delete g_displayDC;
- g_displayDC = NULL;
- }
+ wxDELETE(g_displayDC);
}
//-----------------------------------------------------------------------------
if ( !wxAppBase::OnInitGui() )
return false;
- // MGL redirects stdout and stderr to physical console, so lets redirect
+ // MGL redirects stdout and stderr to physical console, so let's redirect
// it to file if WXSTDERR environment variable is set to be able to see
// wxLogDebug() output
wxString redirect;