Function at 0x41f850
Capabilities:
Write file on windows

Disassembly:
push 0xffffffffffffffff
push 0x46e960
mov eax, dword fs:[0]
push eax
sub esp, 0x10
push ebx
push ebp
push esi
push edi
mov eax, dword [0x498760]
xor eax, esp
push eax
lea eax, [esp + 0x24]
mov dword fs:[0], eax
mov esi, ecx
mov ebx, dword [esp + 0x38]
push 0x477d18
lea eax, [esp + 0x1c]
push ebx
push eax
mov dword [esp + 0x38], 1
call fcn.00454407
add esp, 0xc
test eax, eax
jne 0x4201f0
cmp dword [esp + 0x18], eax
je 0x4201f0
mov edi, dword [esp + 0x34]
push 0x477d14
push edi
push esi
call fcn.00454407
add esp, 0xc
test eax, eax
jne 0x420188
mov eax, dword [esi]
test eax, eax
je 0x420188
xor ebp, ebp
push eax
mov dword [esp + 0x24], ebp
call fcn.00453e6a
add esp, 4
cmp eax, 0x3a
jne 0x41fd5a
mov ecx, esi
call fcn.0041f7e0
mov ecx, esi
mov byte [esp + 0x17], al
call fcn.0041f7e0
xor ecx, ecx
mov ch, al
mov edi, ecx
mov ecx, esi
call fcn.0041f7e0
movzx edx, al
mov ecx, esi
add edi, edx
call fcn.0041f7e0
mov bl, al
cmp bl, 1
je 0x41fa37
lea ecx, [ecx]
cmp bl, 2
je 0x41f92a
cmp bl, 4
jne 0x41f954
mov ecx, esi
call fcn.0041f7e0
xor ecx, ecx
mov ch, al
mov dword [esp + 0x1c], ecx
mov ecx, esi
call fcn.0041f7e0
movzx ebp, al
add ebp, dword [esp + 0x1c]
shl ebp, 4
cmp bl, 4
jne 0x41f954
shl ebp, 0xc
jmp 0x41f970
test bl, bl
jne 0x41f970
add edi, ebp
cmp edi, dword [esp + 0x20]
jb 0x41f970
movzx eax, byte [esp + 0x17]
add eax, edi
mov dword [esp + 0x20], eax
jmp 0x41f970
mov edx, dword [esi]
push edx
call fcn.00453e6a
add esp, 4
cmp eax, 0xffffffff
je 0x41fcdf
cmp eax, 0x3a
jne 0x41f970
mov ecx, esi
call fcn.0041f7e0
mov ecx, esi
mov byte [esp + 0x17], al
call fcn.0041f7e0
xor ecx, ecx
mov ch, al
mov edi, ecx
mov ecx, esi
call fcn.0041f7e0
movzx edx, al
mov ecx, esi
add edi, edx
call fcn.0041f7e0
mov bl, al
cmp bl, 1
jne 0x41f920
mov ebx, dword [esp + 0x20]
test ebx, ebx
je 0x41fa37
push ebx
call fcn.0043666d
mov edi, eax
add esp, 4
test edi, edi
jne 0x41fa14
mov eax, dword [esp + 0x18]
push eax
call fcn.004542c7
mov ecx, dword [esi]
push ecx
call fcn.004542c7
add esp, 8
push str.memory_allocation_error
lea ecx, [esi + 4]
call fcn.0041f100
lea ecx, [esp + 0x34]
call fcn.00401140
lea ecx, [esp + 0x38]
call fcn.00401140
mov eax, 5
jmp 0x420250
push ebx
push 0xff
push edi
call fcn.004527d0
mov edx, dword [esp + 0x24]
push edx
push ebx
push 1
push edi
call fcn.004541c7
push edi
call fcn.00436672
add esp, 0x20
mov eax, dword [esp + 0x18]
push 0
push 0
push eax
mov dword [esp + 0x28], 0
call fcn.00454028
add esp, 0xc
test eax, eax
jne 0x41fca1
mov ecx, dword [esi]
push eax
push 1
push ecx
call fcn.00454028
add esp, 0xc
test eax, eax
jne 0x41fca1
mov ecx, esi
call fcn.0041f7e0
mov ecx, esi
mov byte [esp + 0x17], al
call fcn.0041f7e0
xor edx, edx
mov dh, al
mov ecx, esi
mov edi, edx
call fcn.0041f7e0
movzx eax, al
add edi, eax
mov ecx, esi
mov dword [esp + 0x20], edi
call fcn.0041f7e0
mov bl, al
cmp bl, 1
je 0x41fba7
cmp bl, 2
je 0x41fab2
cmp bl, 4
jne 0x41fae0
mov ecx, esi
call fcn.0041f7e0
xor ecx, ecx
mov ch, al
mov edi, ecx
mov ecx, esi
call fcn.0041f7e0
movzx eax, al
add eax, edi
shl eax, 4
cmp bl, 4
mov dword [esp + 0x1c], eax
jne 0x41fae0
shl eax, 0xc
mov dword [esp + 0x1c], eax
jmp 0x41fb54
test bl, bl
jne 0x41fb54
movzx ebx, byte [esp + 0x17]
mov edx, dword [esp + 0x1c]
add dword [esp + 0x20], edx
push ebx
call fcn.0043666d
mov ebp, eax
add esp, 4
test ebp, ebp
je 0x41fbd5
xor edi, edi
test ebx, ebx
jle 0x41fb21
lea ebx, [ebx]
mov ecx, esi
call fcn.0041f7e0
mov byte [edi + ebp], al
add edi, 1
cmp edi, ebx
jl 0x41fb10
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x18]
push 0
push eax
push ecx
call fcn.00454028
add esp, 0xc
test eax, eax
jne 0x41fc13
mov edx, dword [esp + 0x18]
push edx
push ebx
push 1
push ebp
call fcn.004541c7
push ebp
call fcn.00436672
add esp, 0x14
mov eax, dword [esi]
push eax
call fcn.00453e6a
add esp, 4
cmp eax, 0xffffffff
je 0x41fc5d
cmp eax, 0x3a
jne 0x41fb54
mov ecx, esi
call fcn.0041f7e0
mov ecx, esi
mov byte [esp + 0x17], al
call fcn.0041f7e0
xor ecx, ecx
mov ch, al
mov edi, ecx
mov ecx, esi
call fcn.0041f7e0
movzx edx, al
add edi, edx
mov ecx, esi
mov dword [esp + 0x20], edi
call fcn.0041f7e0
mov bl, al
cmp bl, 1
jne 0x41faa8
mov eax, dword [esp + 0x18]
push eax
call fcn.004542c7
mov ecx, dword [esi]
push ecx
call fcn.004542c7
add esp, 8
lea ecx, [esp + 0x34]
call fcn.00401140
lea ecx, [esp + 0x38]
call fcn.00401140
xor eax, eax
jmp 0x420250
mov edx, dword [esp + 0x18]
push edx
call fcn.004542c7
mov eax, dword [esi]
push eax
call fcn.004542c7
add esp, 8
push str.memory_allocation_error
lea ecx, [esi + 4]
call fcn.0041f100
lea ecx, [esp + 0x34]
call fcn.00401140
lea ecx, [esp + 0x38]
call fcn.00401140
mov eax, 7
jmp 0x420250
push ebp
call fcn.00436672
mov ecx, dword [esp + 0x1c]
push ecx
call fcn.004542c7
mov edx, dword [esi]
push edx
call fcn.004542c7
mov eax, dword [esp + 0x44]
push eax
push str.fseek_function_error_on___s__file
add esi, 4
push esi
call fcn.00402a60
add esp, 0x18
lea ecx, [esp + 0x34]
call fcn.00401140
lea ecx, [esp + 0x38]
call fcn.00401140
mov eax, 0x19
jmp 0x420250
mov ecx, dword [esp + 0x18]
push ecx
call fcn.004542c7
mov edx, dword [esi]
push edx
call fcn.004542c7
mov eax, dword [esp + 0x3c]
push eax
push str.end_of_file_error_on___s__file
add esi, 4
push esi
call fcn.00402a60
add esp, 0x14
lea ecx, [esp + 0x34]
call fcn.00401140
lea ecx, [esp + 0x38]
call fcn.00401140
mov eax, 8
jmp 0x420250
mov ecx, dword [esp + 0x18]
push ecx
call fcn.004542c7
mov edx, dword [esi]
push edx
call fcn.004542c7
add esp, 8
push str.fseek_function_error
lea ecx, [esi + 4]
call fcn.0041f100
lea ecx, [esp + 0x34]
call fcn.00401140
lea ecx, [esp + 0x38]
call fcn.00401140
mov eax, 0x16
jmp 0x420250
mov eax, dword [esp + 0x18]
push eax
call fcn.004542c7
mov ecx, dword [esi]
push ecx
call fcn.004542c7
mov edi, dword [esp + 0x3c]
push edi
push str.end_of_file_error_on___s__file
add esi, 4
push esi
call fcn.00402a60
lea eax, [edi - 0x10]
add esp, 0x14
mov byte [esp + 0x2c], 0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x41fd28
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x38]
add eax, 0xfffffff0
mov dword [esp + 0x2c], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x41fd50
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, 0xa
jmp 0x420250
cmp eax, 0x53
jne 0x420148
mov ecx, dword [esi]
push ecx
call fcn.00453e6a
add esp, 4
cmp eax, 0xffffffff
je 0x41fe12
cmp eax, 0x53
jne 0x41fd63
mov edx, dword [esi]
push edx
call fcn.00453e6a
mov ebx, eax
add esp, 4
cmp ebx, 0x31
je 0x41fd9c
cmp ebx, 0x32
je 0x41fd9c
cmp ebx, 0x33
jne 0x41fe8d
mov ecx, esi
call fcn.0041f7e0
mov ecx, esi
mov byte [esp + 0x17], al
call fcn.0041f7e0
xor ecx, ecx
mov ch, al
mov edi, ecx
mov ecx, esi
call fcn.0041f7e0
add byte [esp + 0x17], 0xfe
movzx edx, al
add edi, edx
cmp ebx, 0x32
je 0x41fdcf
cmp ebx, 0x33
jne 0x41fdfc
mov ecx, esi
call fcn.0041f7e0
add byte [esp + 0x17], 0xff
movzx eax, al
shl edi, 8
add edi, eax
cmp ebx, 0x33
jne 0x41fdfc
mov ecx, esi
call fcn.0041f7e0
movzx ecx, al
shl edi, 8
add edi, ecx
add byte [esp + 0x17], 0xff
cmp edi, ebp
jb 0x41fd63
movzx edx, byte [esp + 0x17]
lea ebp, [edx + edi - 1]
jmp 0x41fd63
mov eax, dword [esp + 0x18]
push eax
call fcn.004542c7
mov ecx, dword [esi]
push ecx
call fcn.004542c7
mov edi, dword [esp + 0x3c]
push edi
push str.end_of_file_error_on___s__file
add esi, 4
push esi
call fcn.00402a60
lea eax, [edi - 0x10]
add esp, 0x14
mov byte [esp + 0x2c], 0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x41fe5b
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x38]
add eax, 0xfffffff0
mov dword [esp + 0x2c], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x41fe83
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, 0xd
jmp 0x420250
test ebp, ebp
je 0x41ff01
push ebp
call fcn.0043666d
mov edi, eax
add esp, 4
test edi, edi
jne 0x41fede
mov ecx, dword [esp + 0x18]
push ecx
call fcn.004542c7
mov edx, dword [esi]
push edx
call fcn.004542c7
add esp, 8
push str.memory_allocation_error
lea ecx, [esi + 4]
call fcn.0041f100
lea ecx, [esp + 0x34]
call fcn.00401140
lea ecx, [esp + 0x38]
call fcn.00401140
mov eax, 9
jmp 0x420250
push ebp
push 0xff
push edi
call fcn.004527d0
mov eax, dword [esp + 0x24]
push eax
push ebp
push 1
push edi
call fcn.004541c7
push edi
call fcn.00436672
add esp, 0x20
mov ecx, dword [esp + 0x18]
push 0
push 0
push ecx
call fcn.00454028
add esp, 0xc
test eax, eax
jne 0x42010a
mov edx, dword [esi]
push eax
push 1
push edx
call fcn.00454028
add esp, 0xc
test eax, eax
jne 0x42010a
mov eax, dword [esi]
push eax
call fcn.00453e6a
add esp, 4
cmp eax, 0xffffffff
je 0x42003e
cmp eax, 0x53
jne 0x41ff30
mov ecx, dword [esi]
push ecx
call fcn.00453e6a
mov edi, eax
add esp, 4
cmp edi, 0x31
je 0x41ff69
cmp edi, 0x32
je 0x41ff69
cmp edi, 0x33
jne 0x41fba7
mov ecx, esi
call fcn.0041f7e0
mov ecx, esi
mov bl, al
call fcn.0041f7e0
xor edx, edx
mov dh, al
mov ecx, esi
mov ebp, edx
call fcn.0041f7e0
movzx eax, al
add ebp, eax
add bl, 0xfe
cmp edi, 0x32
je 0x41ff98
cmp edi, 0x33
jne 0x41ffc1
mov ecx, esi
call fcn.0041f7e0
movzx ecx, al
shl ebp, 8
add ebp, ecx
add bl, 0xff
cmp edi, 0x33
jne 0x41ffc1
mov ecx, esi
call fcn.0041f7e0
movzx edx, al
shl ebp, 8
add ebp, edx
add bl, 0xff
movzx eax, bl
mov dword [esp + 0x20], eax
add eax, 0xffffffff
push eax
mov dword [esp + 0x20], eax
call fcn.0043666d
mov ebx, eax
add esp, 4
test ebx, ebx
je 0x420082
mov eax, dword [esp + 0x20]
add eax, 0xffffffff
xor edi, edi
test eax, eax
mov dword [esp + 0x20], eax
jle 0x420006
mov ecx, esi
call fcn.0041f7e0
mov byte [edi + ebx], al
add edi, 1
cmp edi, dword [esp + 0x20]
jl 0x41fff3
mov eax, dword [esp + 0x18]
push 0
push ebp
push eax
call fcn.00454028
add esp, 0xc
test eax, eax
jne 0x4200c0
mov ecx, dword [esp + 0x18]
mov edx, dword [esp + 0x1c]
push ecx
push edx
push 1
push ebx
call fcn.004541c7
push ebx
call fcn.00436672
add esp, 0x14
jmp 0x41ff30
mov eax, dword [esp + 0x18]
push eax
call fcn.004542c7
mov ecx, dword [esi]
push ecx
call fcn.004542c7
mov edx, dword [esp + 0x3c]
push edx
push str.End_of_file_on___s_
add esi, 4
push esi
call fcn.00402a60
add esp, 0x14
lea ecx, [esp + 0x34]
call fcn.00401140
lea ecx, [esp + 0x38]
call fcn.00401140
mov eax, 0xb
jmp 0x420250
mov edx, dword [esp + 0x18]
push edx
call fcn.004542c7
mov eax, dword [esi]
push eax
call fcn.004542c7
add esp, 8
push str.memory_allocation_error
lea ecx, [esi + 4]
call fcn.0041f100
lea ecx, [esp + 0x34]
call fcn.00401140
lea ecx, [esp + 0x38]
call fcn.00401140
mov eax, 0xc
jmp 0x420250
push ebx
call fcn.00436672
mov ecx, dword [esp + 0x1c]
push ecx
call fcn.004542c7
mov edx, dword [esi]
push edx
call fcn.004542c7
mov eax, dword [esp + 0x44]
push eax
push str.fseek_function_error_on___s__file
add esi, 4
push esi
call fcn.00402a60
add esp, 0x18
lea ecx, [esp + 0x34]
call fcn.00401140
lea ecx, [esp + 0x38]
call fcn.00401140
mov eax, 0x18
jmp 0x420250
mov ecx, dword [esp + 0x18]
push ecx
call fcn.004542c7
mov edx, dword [esi]
push edx
call fcn.004542c7
add esp, 8
push str.fseek_function_error
lea ecx, [esi + 4]
call fcn.0041f100
lea ecx, [esp + 0x34]
call fcn.00401140
lea ecx, [esp + 0x38]
call fcn.00401140
mov eax, 0x17
jmp 0x420250
mov eax, dword [esp + 0x18]
push eax
call fcn.004542c7
mov ecx, dword [esi]
push ecx
call fcn.004542c7
push edi
push str.__s__file_format_is_unknown
add esi, 4
push esi
call fcn.00402a60
add esp, 0x14
lea ecx, [esp + 0x34]
call fcn.00401140
lea ecx, [esp + 0x38]
call fcn.00401140
mov eax, 2
jmp 0x420250
push edi
push str.can_not_open___s_
add esi, 4
push esi
call fcn.00402a60
mov edx, dword [esp + 0x24]
push edx
call fcn.004542c7
lea eax, [edi - 0x10]
add esp, 0x10
mov byte [esp + 0x2c], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4201c5
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea eax, [ebx - 0x10]
mov dword [esp + 0x2c], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4201e9
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, 4
jmp 0x420250
push ebx
push str.can_not_open___s_
add esi, 4
push esi
call fcn.00402a60
mov eax, dword [esp + 0x40]
add eax, 0xfffffff0
add esp, 0xc
mov byte [esp + 0x2c], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x420227
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea eax, [ebx - 0x10]
mov dword [esp + 0x2c], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x42024b
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, 3
mov ecx, dword [esp + 0x24]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c
ret 8