Function at 0x486380
Capabilities:
Write file on windows

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x6c
mov eax, dword [esp + 0x80]
mov edi, dword [esp + 0x9c]
mov edx, dword [eax]
mov eax, dword [edx + 0x20]
cmp eax, 2
je 0x486652
cmp eax, 1
mov ebx, 0xffff
mov ecx, 0xfff
mov eax, 0xff7
cmove ecx, ebx
mov ebx, 0xfff8
mov dword [esp + 0x4c], ecx
mov ecx, 0xff8
cmove ecx, ebx
mov dword [esp + 0x3c], ecx
mov ecx, 0xfff7
cmove eax, ecx
mov dword [esp + 0x40], eax
mov eax, dword [edx + 0x80]
mov dword [esp + 0x50], 0
mov dword [esp + 0x58], 0
add eax, 1
mov dword [esp + 0x5c], 0
mov dword [esp + 0x44], eax
mov eax, dword [esp + 0x84]
mov dword [esp + 0x54], eax
test edi, edi
je 0x486413
mov dword [edi], 0
mov ebx, dword [esp + 0x88]
mov eax, dword [esp + 0x80]
lea ebp, [esp + 0x50]
test ebx, ebx
mov ebx, dword [esp + 0x84]
sete byte [esp + 0x4b]
add eax, 4
xor esi, esi
mov dword [esp + 0x38], eax
jmp 0x4864ff
mov eax, dword [esp + 0x80]
mov dword [esp + 0x14], ebp
mov ecx, ebx
mov dword [esp + 0x10], 0
mov edx, dword [esp + 0x38]
mov dword [esp + 8], 0
mov dword [esp + 0xc], 0
mov dword [esp + 4], 1
mov dword [esp], esi
mov eax, dword [eax]
call fcn.00484270
mov ecx, edx
or ecx, eax
jne 0x486675
mov edx, dword [esp + 0x58]
test edi, edi
je 0x4864d0
mov ebx, dword [edi]
test ebx, ebx
jne 0x4864d0
mov eax, dword [esp + 0x54]
cmp eax, dword [esp + 0x98]
ja 0x4864d0
mov ecx, dword [esp + 0x98]
sub ecx, eax
mov eax, ecx
cmp ecx, edx
jae 0x4864d0
mov ecx, dword [esp + 0xa0]
mov dword [edi], 1
test ecx, ecx
je 0x4864d0
mov ecx, dword [esp + 0xa0]
add eax, esi
mov dword [ecx], eax
lea esi, [esi]
mov ebx, dword [esp + 0x5c]
add esi, edx
cmp ebx, dword [esp + 0x3c]
jb 0x4864e2
cmp ebx, dword [esp + 0x4c]
jbe 0x486517
cmp dword [esp + 0x40], ebx
je 0x486712
cmp ebx, 1
jbe 0x4865b0
cmp dword [esp + 0x44], ebx
jb 0x4865b0
cmp esi, dword [esp + 0x88]
jb 0x486441
cmp byte [esp + 0x4b], 0
jne 0x486441
mov eax, dword [esp + 0x8c]
test eax, eax
je 0x48653c
cmp dword [esp + 0x88], esi
mov eax, esi
mov edi, dword [esp + 0x8c]
cmovbe eax, dword [esp + 0x88]
mov dword [edi], eax
mov ecx, dword [esp + 0x90]
test ecx, ecx
je 0x486575
mov eax, 0
mov edx, esi
sub edx, dword [esp + 0x88]
cmp dword [esp + 0x88], esi
cmova edx, eax
mov eax, dword [esp + 0x58]
add eax, dword [esp + 0x54]
sub eax, 1
mov edi, dword [esp + 0x90]
sub eax, edx
mov dword [edi], eax
mov edx, dword [esp + 0x94]
test edx, edx
je 0x48666f
cmp dword [esp + 0x88], esi
jb 0x48679b
mov eax, dword [esp + 0x5c]
mov edi, dword [esp + 0x94]
xor ecx, ecx
xor edx, edx
mov dword [edi], eax
add esp, 0x6c
mov eax, ecx
pop ebx
pop esi
pop edi
pop ebp
ret
mov edi, dword [esp + 0x54]
mov esi, dword [fcn.004a1b90]
mov dword [esp + 0x38], edx
mov ebp, dword [esp + 0x50]
mov dword [esp], 2
call esi
mov ecx, dword [esp + 0x44]
mov edx, dword [esp + 0x38]
mov dword [esp + 0x20], ebx
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x24], ecx
mov dword [esp + 0xc], edx
mov dword [esp + 0x18], ebp
mov dword [esp + 0x14], edi
mov dword [esp + 0x10], edi
mov dword [esp + 8], 0x54cc60
mov dword [esp + 4], str.__s__Encountered_invalid_FAT_cluster_at_end_of__lu_cluster_extent_starting_at_cluster__FCN___lu__0x_lX__while_searching_for_extent_at_cluster_chain_index__lu:__lu__0x_lX___max_FAT_cluster_number:__lu_
mov dword [esp], eax
call sub.msvcrt.dll_fprintf
mov dword [esp], 2
call esi
mov dword [esp + 8], 2
mov dword [esp + 0xc], eax
mov dword [esp + 4], 1
mov dword [esp], 0x54ccb8
call sub.msvcrt.dll_fwrite
mov dword [esp], 2
call esi
mov dword [esp], eax
call sub.msvcrt.dll_fflush
mov ecx, 0x22
xor edx, edx
add esp, 0x6c
mov eax, ecx
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [esp + 0x4c], 0xfffffff
mov dword [esp + 0x3c], 0xffffff8
mov dword [esp + 0x40], 0xffffff7
jmp 0x4863d9
xor ecx, ecx
xor edx, edx
jmp 0x486648
mov dword [esp + 4], edx
mov dword [esp], eax
mov dword [esp + 0x3c], edx
mov dword [esp + 0x38], eax
call fcn.0041d490
mov esi, dword [fcn.004a1b90]
mov dword [esp], 2
mov edi, eax
call esi
mov ecx, dword [esp + 0x38]
mov dword [esp + 0x18], edi
mov dword [esp + 0x10], ebx
mov dword [esp + 0x14], ecx
mov dword [esp + 0xc], ebx
mov dword [esp + 8], 0x54cc60
mov dword [esp + 4], str.__s__Error_while_getting_extent_starting_at_FAT_cluster_number__lu__0x_lX_:__lu___s_
mov dword [esp], eax
call sub.msvcrt.dll_fprintf
mov dword [esp], 2
call esi
mov dword [esp + 8], 2
mov dword [esp + 0xc], eax
mov dword [esp + 4], 1
mov dword [esp], 0x54ccb8
call sub.msvcrt.dll_fwrite
mov dword [esp], 2
call esi
mov dword [esp], eax
call sub.msvcrt.dll_fflush
mov ecx, dword [esp + 0x38]
mov edx, dword [esp + 0x3c]
add esp, 0x6c
pop ebx
pop esi
mov eax, ecx
pop edi
pop ebp
ret
mov eax, dword [esp + 0x54]
mov ebx, dword [fcn.004a1b90]
mov dword [esp], 2
lea esi, [edx + eax - 1]
call ebx
mov edi, dword [esp + 0x84]
mov dword [esp + 0xc], esi
mov dword [esp + 8], 0x54cc60
mov dword [esp + 0x10], edi
mov dword [esp + 4], str.__s__Encountered_bad_cluster_at_FAT_cluster_number__lu_while_calculating_size_of_FAT_chain_starting_at_FAT_cluster_number:__lu
mov dword [esp], eax
call sub.msvcrt.dll_fprintf
mov dword [esp], 2
call ebx
mov dword [esp + 8], 2
mov dword [esp + 0xc], eax
mov dword [esp + 4], 1
mov dword [esp], 0x54ccb8
call sub.msvcrt.dll_fwrite
mov dword [esp], 2
call ebx
mov dword [esp], eax
call sub.msvcrt.dll_fflush
add esp, 0x6c
mov ecx, 0x16
xor edx, edx
pop ebx
mov eax, ecx
pop esi
pop edi
pop ebp
ret
mov eax, dword [esp + 0x58]
add eax, dword [esp + 0x54]
add eax, dword [esp + 0x88]
sub eax, esi
jmp 0x486595