Function at 0x519148
Capabilities:
Clear file content

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffd0
push ebx
push esi
push edi
xor ecx, ecx
mov dword [ebp - 0xc], ecx
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 8]
call fcn.00404078
xor eax, eax
push ebp
push 0x5194dd
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, dword [ebp - 4]
mov dword [eax + 0x180], 0xffffffff
mov byte [ebp - 0xd], 0
mov eax, dword [ebp - 4]
cmp byte [eax + 0xba], 0
jne 0x5191bc
mov eax, dword [ebp - 4]
mov al, byte [eax + 0x12b]
or al, byte [0x5194ec]
mov edx, dword [ebp - 4]
mov byte [edx + 0x12b], al
mov eax, dword [ebp - 4]
add eax, 0x1de
mov edx, dword [ebp - 8]
call fcn.00403c9c
jmp 0x5194c2
xor edx, edx
push ebp
push 0x519454
push dword fs:[edx]
mov dword fs:[edx], esp
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x1ec]
call fcn.00403ec4
test eax, eax
je 0x5191f2
push 1
lea ecx, [ebp - 0x2e]
mov eax, dword [ebp - 4]
mov edx, dword [eax + 0x1ec]
mov eax, dword [ebp - 4]
call fcn.00516838
mov eax, dword [ebp - 4]
add eax, 0x1de
mov edx, dword [ebp - 8]
call fcn.00403c9c
mov eax, dword [ebp - 4]
cmp dword [eax + 0x180], 0xffffffff
je 0x51944a
mov eax, dword [ebp - 4]
add eax, 0x180
call fcn.0050f080
lea eax, [ebp - 0xc]
push eax
mov cl, 1
mov edx, dword [ebp - 8]
mov eax, dword [ebp - 4]
call fcn.00514890
mov eax, dword [ebp - 0xc]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14a]
call fcn.00403fd4
jne 0x519250
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x5194c2
mov eax, dword [ebp - 0xc]
call fcn.00403ec4
mov ebx, eax
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x1e8]
xor edx, edx
add eax, 0x16
adc edx, 0
push edx
push eax
mov eax, ebx
cdq
add eax, dword [esp]
adc edx, dword [esp + 4]
add esp, 8
cmp edx, 0
jne 0x519286
cmp eax, 0xfffffffe
jbe 0x5192a0
jmp 0x519288
jle 0x5192a0
push 1
mov ecx, 0x27dd
mov dl, 1
mov eax, dword [0x510440]
call fcn.005105bc
call fcn.00403724
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x184]
mov edx, 0x22
call fcn.00409de8
mov esi, eax
mov eax, dword [ebp - 4]
mov dword [eax + 0x180], esi
inc esi
jne 0x5192d9
push 1
mov ecx, 0x2afa
mov dl, 1
mov eax, dword [0x510440]
call fcn.005105bc
call fcn.00403724
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x1e8]
xor edx, edx
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x14], edx
push dword [ebp - 0x14]
push dword [ebp - 0x18]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x180]
xor edx, edx
call fcn.0050e854
cmp edx, 0xffffffff
jne 0x519322
cmp eax, 0xffffffff
jne 0x519322
push 1
mov ecx, 0x2b00
mov dl, 1
mov eax, dword [0x510440]
call fcn.005105bc
call fcn.00403724
lea edx, [ebp - 0x2e]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x180]
mov ecx, 0x16
call fcn.00409e4c
cmp eax, 0x16
jne 0x519346
cmp dword [ebp - 0x2e], 0x6054b50
je 0x51935e
push 1
mov ecx, 0x2b03
mov dl, 1
mov eax, dword [0x510440]
call fcn.005105bc
call fcn.00403724
cmp ebx, 0xffff
jbe 0x51936b
call fcn.00402f70
mov word [ebp - 0x1a], bx
mov dword [ebp - 0x18], 0xffffffea
mov dword [ebp - 0x14], 0xffffffff
push dword [ebp - 0x14]
push dword [ebp - 0x18]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x180]
mov edx, 1
call fcn.0050e854
cmp edx, 0xffffffff
jne 0x5193b8
cmp eax, 0xffffffff
jne 0x5193b8
push 1
mov ecx, 0x2b00
mov dl, 1
mov eax, dword [0x510440]
call fcn.005105bc
call fcn.00403724
mov byte [ebp - 0xd], 1
lea edx, [ebp - 0x2e]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x180]
mov ecx, 0x16
call fcn.00409e78
cmp eax, 0x16
je 0x5193ef
push 1
mov ecx, 0x2b16
mov dl, 1
mov eax, dword [0x510440]
call fcn.005105bc
call fcn.00403724
mov eax, dword [ebp - 0xc]
call fcn.00404088
mov edx, eax
mov ecx, ebx
test ecx, ecx
jns 0x519404
call fcn.00402f70
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x180]
call fcn.00409e78
cmp ebx, eax
je 0x51942e
push 1
mov ecx, 0x2b02
mov dl, 1
mov eax, dword [0x510440]
call fcn.005105bc
call fcn.00403724
mov byte [ebp - 0xd], 0
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x180]
test eax, eax
jns 0x519444
call fcn.00402f70
push eax
call sub.kernel32.dll_SetEndOfFile_1
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x5194a7
mov eax, dword [ebp - 4]
add eax, 0x180
call fcn.0050f080
cmp byte [ebp - 0xd], 0
je 0x5194c2
mov eax, dword [ebp - 4]
call fcn.00517118
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x5194e4
lea eax, [ebp - 0xc]
mov edx, 2
call fcn.00403c6c
ret