Mercurial > mm7
comparison mm7_1.cpp @ 705:e39702f35283
memory allocation partly reworked
author | zipi |
---|---|
date | Mon, 18 Mar 2013 21:50:20 +0000 |
parents | efde64b3e147 |
children | d6236f6a9882 f39d5902c85a |
comparison
equal
deleted
inserted
replaced
704:ef4d646d738d | 705:e39702f35283 |
---|---|
82 GUIButton *j; // esi@7 | 82 GUIButton *j; // esi@7 |
83 | 83 |
84 if ( dword_507CC0 ) | 84 if ( dword_507CC0 ) |
85 { | 85 { |
86 dword_507CC0 = 0; | 86 dword_507CC0 = 0; |
87 for ( i = pGUIWindow_CurrentMenu->pControlsHead; i; i = i->pNext ) | 87 for ( i = pGUIWindow_CurrentMenu->pControlsHead; i; i = j ) |
88 { | 88 { |
89 if ( BYTE1(i->field_1C) & 0x80 ) | 89 j=i->pNext; |
90 if ( BYTE1(i->field_1C) & 0x80 ) | |
91 { | |
90 i->Release(); | 92 i->Release(); |
93 pAllocator->FreeChunk(i); | |
94 } | |
91 } | 95 } |
92 for ( j = pGUIWindow_CurrentMenu->pControlsHead; j; j = j->pNext ) | 96 for ( j = pGUIWindow_CurrentMenu->pControlsHead; j; j = j->pNext ) |
93 { | 97 { |
94 if ( j->uControlID == 120 ) | 98 if ( j->uControlID == 120 ) |
95 { | 99 { |