Function at 0x100789c0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x1007f8c0
mov eax, dword fs:[0]
push eax
sub esp, 0x10
push ebx
push esi
push edi
mov eax, dword [0x1009d350]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 4], 1
mov eax, dword [0x1009d2a8]
mov ecx, 0x1009d2a8
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x10], eax
mov eax, 0x1009231d
mov byte [ebp - 4], 2
test eax, 0xffff0000
jne 0x10078a2c
movzx esi, ax
mov ecx, esi
call fcn.100017b9
test eax, eax
je 0x10078a3b
push esi
push eax
lea ecx, [ebp - 0x10]
call fcn.10007221
jmp 0x10078a3b
push 0
push 0x1009231d
lea ecx, [ebp - 0x10]
call fcn.100081be
mov byte [ebp - 4], 3
mov eax, dword [ebp + 8]
mov dword [ebp - 0x1c], 0x4c7a6f6d
mov esi, dword [eax - 0xc]
mov dword [ebp - 0x18], 0x30347a
lea eax, [esi + 1]
push eax
call fcn.1004b5a0
mov edi, eax
mov byte [edi + esi], 0
push dword [ebp + 8]
push 0x10092414
push edi
call fcn.1004c19c
mov ecx, esi
call fcn.10017ef0
add eax, 0xc
push eax
call fcn.1004df72
mov ebx, eax
add esp, 0x14
test ebx, ebx
jne 0x10078aa1
test edi, edi
je 0x10078b54
push edi
call fcn.1004d54b
add esp, 4
xor bl, bl
jmp 0x10078b91
movq xmm0, qword [ebp - 0x1c]
movq qword [ebx], xmm0
mov edx, 8
xor ecx, ecx
mov eax, esi
shr eax, cl
inc edx
add ecx, 8
mov byte [edx + ebx - 1], al
cmp edx, 0xc
jb 0x10078ab1
push esi
add edx, ebx
mov ecx, edi
call fcn.100183a0
add esp, 4
test eax, eax
jne 0x10078af0
push ebx
call fcn.1004d54b
add esp, 4
test edi, edi
je 0x10078b54
push edi
call fcn.1004d54b
add esp, 4
xor bl, bl
jmp 0x10078b91
add eax, 0xc
mov dword [ebp - 0x18], eax
mov eax, dword [ebp + 0xc]
mov esi, dword [eax - 0xc]
lea eax, [esi + 1]
push eax
call fcn.1004b5a0
mov byte [eax + esi], 0
push dword [ebp + 0xc]
mov esi, eax
push 0x10092414
push esi
mov dword [ebp - 0x14], eax
call fcn.1004c19c
push 0x10097398
push esi
call fcn.1004f200
add esp, 0x18
mov dword [ebp - 0x14], eax
test eax, eax
jne 0x10078b58
push ebx
call fcn.1004d54b
add esp, 4
test edi, edi
je 0x10078b47
push edi
call fcn.1004d54b
add esp, 4
test esi, esi
je 0x10078b54
push esi
call fcn.1004d54b
add esp, 4
xor bl, bl
jmp 0x10078b91
push eax
push dword [ebp - 0x18]
push 1
push ebx
call fcn.1005210a
push dword [ebp - 0x14]
call fcn.1004ef86
push ebx
call fcn.1004d54b
add esp, 0x18
test edi, edi
je 0x10078b82
push edi
call fcn.1004d54b
add esp, 4
test esi, esi
je 0x10078b8f
push esi
call fcn.1004d54b
add esp, 4
mov bl, 1
mov byte [ebp - 4], 1
mov edx, dword [ebp - 0x10]
add edx, 0xfffffff0
or esi, 0xffffffff
lea ecx, [edx + 0xc]
mov eax, esi
lock xadd dword [ecx], eax
dec eax
test eax, eax
jg 0x10078bb4
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [ebp - 4], 0
mov edx, dword [ebp + 8]
add edx, 0xfffffff0
mov ecx, esi
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x10078bd4
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov dword [ebp - 4], 0xffffffff
mov edi, dword [ebp + 0xc]
add edi, 0xfffffff0
lea eax, [edi + 0xc]
lock xadd dword [eax], esi
dec esi
test esi, esi
jg 0x10078bf5
mov ecx, dword [edi]
push edi
mov edx, dword [ecx]
call dword [edx + 4]
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8