File tree Expand file tree Collapse file tree 6 files changed +21
-6
lines changed Expand file tree Collapse file tree 6 files changed +21
-6
lines changed Original file line number Diff line number Diff line change @@ -248,7 +248,7 @@ BOOL CMUSHclientApp::InitInstance()
248
248
// where we do file browsing from
249
249
strcpy (file_browsing_dir, working_dir);
250
250
251
- // bc_init_numbers();
251
+ bc_init_numbers ();
252
252
253
253
254
254
// First free the string that was allocated by MFC in the startup
@@ -396,7 +396,7 @@ BOOL CMUSHclientApp::InitInstance()
396
396
397
397
// Set the debug-heap flag so that freed blocks are kept on the
398
398
// linked list, to catch any inadvertent use of freed memory
399
- // SET_CRT_DEBUG_FIELD( _CRTDBG_DELAY_FREE_MEM_DF );
399
+ SET_CRT_DEBUG_FIELD ( _CRTDBG_DELAY_FREE_MEM_DF );
400
400
SET_CRT_DEBUG_FIELD ( _CRTDBG_LEAK_CHECK_DF );
401
401
// SET_CRT_DEBUG_FIELD( _CRTDBG_CHECK_ALWAYS_DF );
402
402
// speed warning: see: _ASSERTE( _CrtCheckMemory( ) );
@@ -1223,7 +1223,7 @@ int CMUSHclientApp::ExitInstance()
1223
1223
1224
1224
THEMEGLUE_FREE ();
1225
1225
1226
- // bc_free_numbers (); // free zero, one, two
1226
+ bc_free_numbers (); // free zero, one, two
1227
1227
1228
1228
// free the resources DLL
1229
1229
FreeLibrary (m_hInstDLL);
Original file line number Diff line number Diff line change @@ -59,6 +59,8 @@ CTextView::CTextView()
59
59
CTextView::~CTextView ()
60
60
{
61
61
delete m_font;
62
+ if (m_backbr)
63
+ m_backbr->DeleteObject ();
62
64
delete m_backbr;
63
65
}
64
66
@@ -186,6 +188,10 @@ void CTextView::OnInitialUpdate()
186
188
187
189
SetTheFont ();
188
190
191
+ if (m_backbr)
192
+ m_backbr->DeleteObject ();
193
+ delete m_backbr;
194
+
189
195
m_backbr = new CBrush (pDoc->m_backColour );
190
196
m_backcolour = pDoc->m_backColour ;
191
197
@@ -757,6 +763,8 @@ CRect rect;
757
763
// recreate background colour if necessary
758
764
if (m_backcolour != pDoc->m_backColour )
759
765
{
766
+ if (m_backbr)
767
+ m_backbr->DeleteObject ();
760
768
delete m_backbr;
761
769
m_backbr = new CBrush (pDoc->m_backColour );
762
770
m_backcolour = pDoc->m_backColour ;
Original file line number Diff line number Diff line change @@ -643,7 +643,7 @@ int i;
643
643
delete dbit->second ; // now delete memory used by it
644
644
}
645
645
646
- }
646
+ } // end of CMUSHclientDoc::~CMUSHclientDoc
647
647
648
648
649
649
BOOL CMUSHclientDoc::OnNewDocument ()
Original file line number Diff line number Diff line change 1562
1562
#ifdef APSTUDIO_INVOKED
1563
1563
#ifndef APSTUDIO_READONLY_SYMBOLS
1564
1564
#define _APS_3D_CONTROLS 1
1565
- #define _APS_NEXT_RESOURCE_VALUE 363
1565
+ #define _APS_NEXT_RESOURCE_VALUE 364
1566
1566
#define _APS_NEXT_COMMAND_VALUE 33054
1567
1567
#define _APS_NEXT_CONTROL_VALUE 2897
1568
1568
#define _APS_NEXT_SYMED_VALUE 312
Original file line number Diff line number Diff line change @@ -274,7 +274,7 @@ static const luaL_reg R[] =
274
274
275
275
LUALIB_API int luaopen_bc (lua_State * L )
276
276
{
277
- bc_init_numbers ();
277
+ // bc_init_numbers(); // done once in MUSHclient.cpp
278
278
lua_pushliteral (L ,MYNAME );
279
279
luaL_newmetatable (L ,MYTYPE );
280
280
luaL_openlib (L ,NULL ,R ,0 );
Original file line number Diff line number Diff line change @@ -265,6 +265,8 @@ CSendView::CSendView()
265
265
266
266
CSendView::~CSendView ()
267
267
{
268
+ if (m_backbr)
269
+ m_backbr->DeleteObject ();
268
270
delete m_backbr;
269
271
}
270
272
@@ -1127,6 +1129,8 @@ CRect rect;
1127
1129
// recreate background colour if necessary
1128
1130
if (m_backcolour != pDoc->m_input_background_colour )
1129
1131
{
1132
+ if (m_backbr)
1133
+ m_backbr->DeleteObject ();
1130
1134
delete m_backbr;
1131
1135
m_backbr = new CBrush (pDoc->m_input_background_colour );
1132
1136
m_backcolour = pDoc->m_input_background_colour ;
@@ -1207,6 +1211,9 @@ void CSendView::OnInitialUpdate()
1207
1211
1208
1212
m_owner_frame->FixUpSplitterBar ();
1209
1213
1214
+ if (m_backbr)
1215
+ m_backbr->DeleteObject ();
1216
+ delete m_backbr;
1210
1217
m_backbr = new CBrush (pDoc->m_input_background_colour );
1211
1218
m_backcolour = pDoc->m_input_background_colour ;
1212
1219
You can’t perform that action at this time.
0 commit comments