Function at 0x460160
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x2dc0
call fcn.004ab2b0
mov eax, dword [0x523034]
xor eax, ebp
mov dword [ebp - 8], eax
mov eax, dword [ebp + 0xc]
xorps xmm0, xmm0
push ebx
mov dword [ebp - 0x2db4], eax
xor eax, eax
push esi
mov dword [ebp - 0x2d94], eax
mov dword [ebp - 0x2d90], eax
mov dword [ebp - 0x2dac], eax
lea eax, [ebp - 0x274]
push edi
push eax
mov dword [ebp - 0x2da0], edx
mov edi, ecx
movlpd qword [ebp - 0x2dbc], xmm0
movlpd qword [ebp - 0x2d9c], xmm0
call fcn.0045ffb0
add esp, 4
test eax, eax
jne 0x4601d8
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.004aa896
mov esp, ebp
pop ebp
ret
mov ebx, dword [ebp - 0x254]
mov eax, ebx
mov esi, dword [ebp - 0x250]
or eax, esi
mov dword [ebp - 0x2d78], ebx
mov dword [ebp - 0x2d84], esi
jne 0x46020c
mov eax, 1
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.004aa896
mov esp, ebp
pop ebp
ret
test edi, edi
je 0x460247
mov ecx, dword [edi + 0x48]
test ecx, ecx
je 0x460247
mov edx, dword [ebp - 0x2da0]
cmp edx, dword [edi + 0x10]
jae 0x460247
cmp dword [edi + 0x14], 1
jne 0x460247
mov eax, dword [ecx + 0x10]
mov eax, dword [eax + edx*4]
add eax, dword [ecx]
je 0x460247
movzx ecx, word [eax + 0x1c]
test ecx, ecx
je 0x460241
cmp byte [ecx + eax + 0x2d], 0x2f
je 0x4601f6
test byte [eax + 0x26], 0x10
jne 0x4601f6
test byte [ebp - 0x268], 0x21
jne 0x4601c5
mov ax, word [ebp - 0x266]
test ax, ax
je 0x46026a
cmp ax, 8
jne 0x4601c5
push 0x1e
lea eax, [ebp - 0x28]
push eax
push dword [ebp - 0x238]
mov eax, dword [edi + 0x38]
push dword [ebp - 0x23c]
push dword [edi + 0x44]
call eax
add esp, 0x14
cmp eax, 0x1e
jne 0x4601c5
cmp dword [ebp - 0x28], 0x4034b50
jne 0x4601c5
movzx eax, word [ebp - 0xe]
cdq
mov ecx, eax
mov dword [ebp - 0x2d74], edx
movzx eax, word [ebp - 0xc]
cdq
add ecx, eax
mov eax, dword [ebp - 0x2d74]
adc eax, edx
add ecx, dword [ebp - 0x23c]
adc eax, dword [ebp - 0x238]
add ecx, 0x1e
mov edx, ecx
mov dword [ebp - 0x2d8c], ecx
adc eax, 0
add edx, ebx
mov dword [ebp - 0x2d74], eax
adc eax, esi
cmp eax, dword [edi + 4]
jb 0x4602f0
ja 0x4601c5
cmp edx, dword [edi]
ja 0x4601c5
mov eax, dword [edi + 0x48]
mov eax, dword [eax + 0x48]
test eax, eax
je 0x460334
xorps xmm0, xmm0
mov dword [ebp - 0x2d6c], ebx
lea edx, [eax + ecx]
movlpd qword [ebp - 0x2da4], xmm0
mov dword [ebp - 0x2d80], esi
mov dword [ebp - 0x2d88], ebx
mov ebx, dword [ebp - 0x2da4]
mov dword [ebp - 0x2da8], esi
mov esi, dword [ebp - 0x2da0]
mov dword [ebp - 0x2d7c], edx
jmp 0x4603a0
test esi, esi
ja 0x46034c
jb 0x460342
cmp ebx, 0x10000
jae 0x46034c
mov eax, ebx
mov dword [ebp - 0x2da8], esi
jmp 0x460359
xor ecx, ecx
mov eax, 0x10000
mov dword [ebp - 0x2da8], ecx
push eax
push 1
push dword [edi + 0x34]
mov dword [ebp - 0x2d88], eax
mov eax, dword [edi + 0x28]
call eax
mov edx, eax
add esp, 0xc
mov dword [ebp - 0x2d7c], edx
test edx, edx
je 0x4601c5
xorps xmm0, xmm0
movlpd qword [ebp - 0x2da4], xmm0
mov eax, dword [ebp - 0x2da0]
mov dword [ebp - 0x2d80], eax
mov eax, dword [ebp - 0x2da4]
mov dword [ebp - 0x2d6c], eax
cmp word [ebp - 0x266], 0
mov dword [ebp - 0x2d70], esi
mov dword [ebp - 0x2d68], ebx
je 0x46062e
mov eax, dword [edi + 0x28]
push 0x8000
push 1
push dword [edi + 0x34]
mov dword [ebp - 0x2d64], 0
call eax
add esp, 0xc
mov dword [ebp - 0x2dac], eax
test eax, eax
jne 0x4603e8
or ebx, 0xffffffff
jmp 0x4607f1
mov eax, dword [ebp - 0x2db8]
mov edx, dword [ebp - 0x2d6c]
mov dword [ebp - 0x2db0], eax
mov eax, dword [ebp - 0x2dbc]
mov dword [ebp - 0x2d68], eax
mov eax, dword [ebp - 0x2d98]
mov dword [ebp - 0x2d84], eax
mov eax, dword [ebp - 0x2d9c]
mov dword [ebp - 0x2d78], eax
nop
mov ecx, eax
mov eax, dword [ebp - 0x2dac]
and ecx, 0x7fff
add eax, ecx
mov dword [ebp - 0x2d98], eax
mov eax, 0x8000
sub eax, ecx
mov dword [ebp - 0x2d70], eax
mov eax, edx
or eax, dword [ebp - 0x2d80]
jne 0x460502
mov eax, dword [edi + 0x48]
cmp dword [eax + 0x48], 0
jne 0x460502
mov ecx, dword [ebp - 0x2da8]
cmp ecx, esi
ja 0x460482
mov eax, dword [ebp - 0x2d88]
jb 0x460474
cmp eax, ebx
jae 0x460482
mov dword [ebp - 0x2d6c], eax
mov dword [ebp - 0x2d80], ecx
jmp 0x460490
mov eax, ebx
mov dword [ebp - 0x2d6c], ebx
mov dword [ebp - 0x2d80], esi
mov edx, dword [ebp - 0x2d74]
push eax
push dword [ebp - 0x2d7c]
mov eax, dword [edi + 0x38]
push edx
push dword [ebp - 0x2d8c]
push dword [edi + 0x44]
call eax
mov edx, dword [ebp - 0x2d6c]
add esp, 0x14
xor ecx, ecx
cmp eax, edx
jne 0x4603e0
mov eax, dword [ebp - 0x2d80]
cmp ecx, eax
jne 0x4603e0
add dword [ebp - 0x2d8c], edx
xorps xmm0, xmm0
movlpd qword [ebp - 0x2dbc], xmm0
adc dword [ebp - 0x2d74], eax
sub ebx, edx
mov ecx, dword [ebp - 0x2dbc]
sbb esi, eax
mov dword [ebp - 0x2d68], ecx
mov eax, dword [ebp - 0x2db8]
mov dword [ebp - 0x2db0], eax
jmp 0x460508
mov ecx, dword [ebp - 0x2d68]
mov eax, ebx
mov dword [ebp - 0x2da0], edx
or eax, esi
je 0x46051b
mov eax, 2
jmp 0x46051d
xor eax, eax
mov edx, dword [ebp - 0x2d7c]
push eax
lea eax, [ebp - 0x2d70]
push eax
push dword [ebp - 0x2d98]
lea eax, [ebp - 0x2da0]
push dword [ebp - 0x2dac]
lea edx, [ecx + edx]
push eax
lea ecx, [ebp - 0x2d64]
call fcn.0045d5c0
mov edx, dword [ebp - 0x2d6c]
add esp, 0x14
mov ecx, dword [ebp - 0x2da0]
sub edx, ecx
mov dword [ebp - 0x2d94], eax
sbb dword [ebp - 0x2d80], 0
add dword [ebp - 0x2d68], ecx
mov eax, dword [ebp - 0x2d70]
adc dword [ebp - 0x2db0], 0
mov dword [ebp - 0x2d6c], edx
test eax, eax
je 0x46060e
push dword [ebp - 0x2db4]
push eax
push 1
push dword [ebp - 0x2d98]
call fcn.004b65b1
mov ecx, dword [ebp - 0x2d70]
add esp, 0x10
cmp eax, ecx
jne 0x4603e0
mov edx, dword [ebp - 0x2d98]
push ecx
mov ecx, dword [ebp - 0x2d90]
call fcn.0045d510
mov ecx, dword [ebp - 0x2d84]
add esp, 4
mov dword [ebp - 0x2d90], eax
mov eax, dword [ebp - 0x2d78]
add eax, dword [ebp - 0x2d70]
mov dword [ebp - 0x2d78], eax
adc ecx, 0
mov dword [ebp - 0x2d84], ecx
cmp ecx, dword [ebp - 0x248]
ja 0x4603e0
jb 0x460606
cmp eax, dword [ebp - 0x24c]
ja 0x4603e0
mov edx, dword [ebp - 0x2d6c]
jmp 0x460614
mov eax, dword [ebp - 0x2d78]
mov ecx, dword [ebp - 0x2d94]
cmp ecx, 1
je 0x460420
cmp ecx, 2
je 0x460420
jmp 0x460692
mov eax, dword [edi + 0x48]
cmp dword [eax + 0x48], 0
je 0x4606ab
mov esi, dword [ebp - 0x250]
test esi, esi
jne 0x4601c5
mov ebx, dword [ebp - 0x254]
cmp ebx, 0xffffffff
ja 0x4601c5
push dword [ebp - 0x2db4]
push ebx
push 1
push edx
call fcn.004b65b1
add esp, 0x10
xor ecx, ecx
cmp eax, ebx
jne 0x460689
cmp ecx, esi
jne 0x460689
mov edx, dword [ebp - 0x2d7c]
push ebx
call fcn.0045d510
add esp, 4
mov dword [ebp - 0x2d90], eax
xor ecx, ecx
jmp 0x460692
or ecx, 0xffffffff
mov dword [ebp - 0x2d94], ecx
test ecx, ecx
jne 0x4607eb
mov ecx, dword [ebp - 0x2d78]
mov edx, dword [ebp - 0x2d84]
jmp 0x4607c0
mov eax, ebx
or eax, esi
je 0x4607b4
mov eax, dword [ebp - 0x2d98]
mov dword [ebp - 0x2d84], eax
mov eax, dword [ebp - 0x2d9c]
mov dword [ebp - 0x2d78], eax
nop dword [eax]
mov ecx, dword [ebp - 0x2da8]
cmp ecx, esi
ja 0x4606ec
mov eax, dword [ebp - 0x2d88]
jb 0x4606e6
cmp eax, ebx
jae 0x4606ec
mov esi, eax
mov ebx, ecx
jmp 0x4606f4
mov esi, ebx
mov ebx, dword [ebp - 0x2d70]
mov edx, dword [ebp - 0x2d74]
mov eax, dword [edi + 0x38]
push esi
push dword [ebp - 0x2d7c]
push edx
push dword [ebp - 0x2d8c]
push dword [edi + 0x44]
call eax
add esp, 0x14
xor ecx, ecx
cmp eax, esi
jne 0x4603e0
cmp ecx, ebx
jne 0x4603e0
mov edx, dword [ebp - 0x2d7c]
mov ecx, dword [ebp - 0x2d90]
push esi
call fcn.0045d510
push dword [ebp - 0x2db4]
mov dword [ebp - 0x2d90], eax
push esi
push 1
push dword [ebp - 0x2d7c]
call fcn.004b65b1
add esp, 0x14
xor ecx, ecx
cmp eax, esi
jne 0x4603e0
cmp ecx, ebx
jne 0x4603e0
add dword [ebp - 0x2d8c], esi
mov ecx, dword [ebp - 0x2d78]
adc dword [ebp - 0x2d74], ebx
add ecx, esi
mov edx, dword [ebp - 0x2d84]
adc edx, ebx
mov dword [ebp - 0x2d78], ecx
sub dword [ebp - 0x2d68], esi
mov esi, dword [ebp - 0x2d70]
sbb esi, ebx
mov dword [ebp - 0x2d84], edx
mov ebx, dword [ebp - 0x2d68]
mov eax, ebx
or eax, esi
mov dword [ebp - 0x2d70], esi
jne 0x4606d0
jmp 0x4607c0
mov edx, dword [ebp - 0x2d98]
mov ecx, dword [ebp - 0x2d9c]
cmp ecx, dword [ebp - 0x24c]
jne 0x4603e0
cmp edx, dword [ebp - 0x248]
jne 0x4603e0
mov eax, dword [ebp - 0x2d90]
cmp eax, dword [ebp - 0x25c]
je 0x4607eb
or ebx, 0xffffffff
jmp 0x4607f1
mov ebx, dword [ebp - 0x2d94]
mov eax, dword [edi + 0x48]
cmp dword [eax + 0x48], 0
jne 0x46080b
push dword [ebp - 0x2d7c]
mov eax, dword [edi + 0x2c]
push dword [edi + 0x34]
call eax
add esp, 8
mov eax, dword [ebp - 0x2dac]
test eax, eax
je 0x460821
push eax
push dword [edi + 0x34]
mov eax, dword [edi + 0x2c]
call eax
add esp, 8
mov ecx, dword [ebp - 8]
xor eax, eax
test ebx, ebx
pop edi
sete al
xor ecx, ebp
pop esi
pop ebx
call fcn.004aa896
mov esp, ebp
pop ebp
ret