ISO9660 bugfixes

git-svn-id: svn://kolibrios.org@364 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
Evgeny Grechnikov (Diamond) 2007-02-19 14:31:28 +00:00
parent 0f0c0aabfa
commit b000e7656d
2 changed files with 37 additions and 33 deletions

View File

@ -190,6 +190,7 @@ proc fs_execute
mov [save_cr3], ebx mov [save_cr3], ebx
stdcall create_app_space,[hdr_mem],[file_base],[file_size] stdcall create_app_space,[hdr_mem],[file_base],[file_size]
mov ecx, -30 ; no memory
test eax, eax test eax, eax
jz .failed jz .failed

View File

@ -65,7 +65,9 @@ free_cd_channel:
mov [IDE_Channel_2],0 mov [IDE_Channel_2],0
ret ret
uglobal
cd_status dd 0 cd_status dd 0
endg
;---------------------------------------------------------------- ;----------------------------------------------------------------
; ;
@ -253,15 +255,18 @@ fs_CdReadFolder:
call .get_names_from_buffer call .get_names_from_buffer
sub eax,2048 sub eax,2048
; äèðåêòîðèÿ çàêîí÷èëàñü? ; äèðåêòîðèÿ çàêîí÷èëàñü?
cmp eax,0
ja .read_to_buffer ja .read_to_buffer
mov edi, [cd_counter_block] mov edi, [cd_counter_block]
mov [edx+8], edi mov [edx+8], edi
mov edi, [ebx] mov edi, [ebx]
sub [edx+4], edi sub [edx+4], edi
xor eax, eax
dec ecx
js @f
mov al, ERROR_END_OF_FILE
@@:
pop ecx edi pop ecx edi
mov ebx, [edx+4] mov ebx, [edx+4]
mov eax,ERROR_SUCCESS
ret ret
.get_names_from_buffer: .get_names_from_buffer:
@ -658,11 +663,9 @@ cd_find_lfn:
cmp byte [esi-1], 0 cmp byte [esi-1], 0
jz .done jz .done
mov eax,[cd_current_pointer_of_input] mov eax,[cd_current_pointer_of_input]
add eax,2 push dword [eax+2]
mov eax,[eax] pop dword [CDSectorAddress] ; íà÷àëî äèðåêòîðèè
mov [CDSectorAddress],eax ; начало директории mov eax,[eax+2+8] ; ðàçìåð äèðåêòîðèè
add eax,8
mov eax,[eax] ; размер директории
jmp .mainloop jmp .mainloop
; óêàçàòåëü ôàéëà íàéäåí ; óêàçàòåëü ôàéëà íàéäåí
.done: .done: