- gs_savedCursor = new wxCursor;
- if ( g_globalCursor && g_globalCursor->Ok() )
- *gs_savedCursor = *g_globalCursor;
- else
- *gs_savedCursor = wxCursor(wxCURSOR_ARROW);
- wxSetCursor(wxCursor(wxCURSOR_WATCH));
+ wxASSERT_MSG( !gs_savedCursor.Ok(),
+ wxT("forgot to call wxEndBusyCursor, will leak memory") );
+
+ gs_savedCursor = g_globalCursor;
+
+ wxSetCursor( wxCursor(wxCURSOR_WATCH) );
+
+ wxYield();