Rev 943 | Rev 983 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 943 | Rev 945 | ||
---|---|---|---|
Line 3... | Line 3... | ||
3 | ;; Copyright (C) KolibriOS team 2004-2007. All rights reserved. ;; |
3 | ;; Copyright (C) KolibriOS team 2004-2007. All rights reserved. ;; |
4 | ;; Distributed under terms of the GNU General Public License ;; |
4 | ;; Distributed under terms of the GNU General Public License ;; |
5 | ;; ;; |
5 | ;; ;; |
6 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
6 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
Line 7... | Line 7... | ||
7 | 7 | ||
Line 8... | Line 8... | ||
8 | $Revision: 943 $ |
8 | $Revision: 945 $ |
9 | 9 | ||
10 | 10 | ||
Line 1147... | Line 1147... | ||
1147 | destroy_smap: |
1147 | destroy_smap: |
Line 1148... | Line 1148... | ||
1148 | 1148 | ||
1149 | pushfd |
1149 | pushfd |
Line 1150... | Line 1150... | ||
1150 | cli |
1150 | cli |
1151 | 1151 | ||
Line -... | Line 1152... | ||
- | 1152 | push esi |
|
1152 | push ebx |
1153 | push edi |
1153 | mov ebx, eax |
1154 | |
1154 | 1155 | mov edi, eax |
|
Line 1155... | Line -... | ||
1155 | mov eax, [eax+SMAP.base] |
- | |
1156 | test eax, eax |
- | |
1157 | jz @F |
1156 | mov esi, [eax+SMAP.parent] |
1158 | - | ||
1159 | stdcall user_free, eax |
1157 | test esi, esi |
Line -... | Line 1158... | ||
- | 1158 | jz .done |
|
1160 | @@: |
1159 | |
- | 1160 | lock dec [esi+SMEM.refcount] |
|
- | 1161 | jnz .done |
|
- | 1162 | ||
- | 1163 | mov ecx, [esi+SMEM.bk] |
|
- | 1164 | mov edx, [esi+SMEM.fd] |
|
- | 1165 | ||
- | 1166 | mov [ecx+SMEM.fd], edx |
|
1161 | mov eax, [ebx+SMAP.parent] |
1167 | mov [edx+SMEM.bk], ecx |
1162 | test eax, eax |
1168 | |
1163 | jz @F |
1169 | stdcall kernel_free, [esi+SMEM.base] |
Line -... | Line 1170... | ||
- | 1170 | mov eax, esi |
|
1164 | 1171 | call free |
|
1165 | lock dec [eax+SMEM.refcount] |
1172 | .done: |
Line 1166... | Line 1173... | ||
1166 | @@: |
1173 | mov eax, edi |
Line 1167... | Line 1174... | ||
1167 | mov eax, ebx |
1174 | call destroy_kernel_object |
Line 1393... | Line 1400... | ||
1393 | test eax, eax |
1400 | test eax, eax |
1394 | jz .fail |
1401 | jz .fail |
Line 1395... | Line 1402... | ||
1395 | 1402 | ||
1396 | push esi |
1403 | push esi |
- | 1404 | push edi |
|
- | 1405 | pushfd |
|
Line 1397... | Line 1406... | ||
1397 | push edi |
1406 | cli |
1398 | 1407 | ||
1399 | mov esi, [current_slot] |
1408 | mov esi, [current_slot] |
1400 | add esi, APP_OBJ_OFFSET |
1409 | add esi, APP_OBJ_OFFSET |
Line 1417... | Line 1426... | ||
1417 | lea eax, [edi+SMEM.name] |
1426 | lea eax, [edi+SMEM.name] |
1418 | stdcall strncmp, [name], edi, 32 |
1427 | stdcall strncmp, [name], edi, 32 |
1419 | test eax, eax |
1428 | test eax, eax |
1420 | jne .next |
1429 | jne .next |
Line -... | Line 1430... | ||
- | 1430 | ||
- | 1431 | stdcall user_free, [esi+SMAP.base] |
|
1421 | 1432 | ||
1422 | call [esi+APPOBJ.destroy] |
1433 | call [esi+APPOBJ.destroy] |
- | 1434 | @@: |
|
1423 | @@: |
1435 | popfd |
1424 | pop edi |
1436 | pop edi |
1425 | pop esi |
1437 | pop esi |
1426 | .fail: |
1438 | .fail: |
1427 | ret |
1439 | ret |