Function at 0x4d4f10
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10c
mov eax, dword [0x582654]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, ecx
cmp byte [ebx + 0x20], 0
je 0x4d4f3d
mov al, 1
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0052388c
mov esp, ebp
pop ebp
ret
push esi
push edi
push 0x57cec4
lea esi, [ebx + 0x24]
call fcn.004d9ef0
push eax
push esi
call fcn.004d93e0
add esp, 0xc
lea eax, [ebp - 0x108]
mov ecx, ebx
push 0x104
push eax
call fcn.004d47e0
lea edi, [ebp - 0x108]
dec edi
mov al, byte [edi + 1]
lea edi, [edi + 1]
test al, al
jne 0x4d4f70
mov ax, word [0x57c370]
push 0x57ced8
mov word [edi], ax
call fcn.004d9ef0
mov edx, eax
add esp, 4
mov esi, edx
mov al, byte [edx]
inc edx
test al, al
jne 0x4d4f94
lea edi, [ebp - 0x108]
sub edx, esi
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x4d4fa4
mov ecx, edx
lea eax, [ebp - 0x108]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
push 0x57cee8
call fcn.004d9ef0
add esp, 4
lea esi, [ebx + 0x24]
push eax
push esi
call fcn.004d93e0
add esp, 0xc
lea eax, [ebp - 0x108]
lea ecx, [ebx + 0x3d14]
push 1
push eax
call fcn.004db3a0
test al, al
jne 0x4d5032
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
mov edi, dword [ebx + 0x3d58]
call esi
push eax
push edi
push 0x57cef4
call fcn.004d9ef0
add esp, 4
lea esi, [ebx + 0x24]
push eax
push esi
call fcn.004d93e0
add esp, 0x10
xor al, al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0052388c
mov esp, ebp
pop ebp
ret
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov dword [ebx + 0x3d64], eax
test eax, eax
jne 0x4d505a
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x57cf14
jmp 0x4d51d4
push 2
push eax
call fcn.004d59a0
push 1
push dword [ebx + 0x3d64]
mov dword [ebx + 0x3d84], eax
call fcn.004d59a0
push 3
push dword [ebx + 0x3d64]
mov dword [ebx + 0x3d88], eax
call fcn.004d59a0
push 4
push dword [ebx + 0x3d64]
mov dword [ebx + 0x3d8c], eax
call fcn.004d59a0
cmp dword [ebx + 0x3d84], 0
mov dword [ebx + 0x3d90], eax
je 0x4d51c8
cmp dword [ebx + 0x3d88], 0
je 0x4d51c8
cmp dword [ebx + 0x3d8c], 0
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
jne 0x4d50e4
call edi
push eax
push 0x57cf48
call fcn.004d9ef0
add esp, 4
push eax
push esi
call fcn.004d93e0
add esp, 0xc
cmp dword [ebx + 0x3d90], 0
jne 0x4d5107
call edi
push eax
push 0x57cf48
call fcn.004d9ef0
add esp, 4
push eax
push esi
call fcn.004d93e0
add esp, 0xc
push 0
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateEventA]
mov dword [ebx + 0x14], eax
test eax, eax
jne 0x4d5129
call edi
push eax
push 0x57cf60
jmp 0x4d51d4
lea eax, [ebp - 0x10c]
mov byte [ebx + 0x20], 1
push eax
push 0
push ebx
push 0x4d9310
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov dword [ebx + 0x3d68], eax
test eax, eax
jne 0x4d515a
call edi
push eax
push 0x57cf88
jmp 0x4d51d4
push dword [ebp - 0x10c]
push 0x57cfac
call fcn.004d9ef0
add esp, 4
push eax
push esi
call fcn.004d93e0
push dword [ebx + 0x14]
mov eax, dword [ebx + 0x3d84]
push dword [ebx + 0x3d70]
push dword [ebx + 0x3d74]
push dword [ebx + 0x146c]
call eax
add esp, 0x1c
cmp eax, 0x6b
je 0x4d51a1
push eax
push 0x57cfd0
jmp 0x4d51d4
push 0x57cfec
call fcn.004d9ef0
push eax
push esi
call fcn.004d93e0
add esp, 0xc
mov al, 1
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0052388c
mov esp, ebp
pop ebp
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x57cf30
call fcn.004d9ef0
add esp, 4
push eax
push esi
call fcn.004d93e0
mov ecx, dword [ebp - 4]
add esp, 0xc
xor ecx, ebp
xor al, al
pop edi
pop esi
pop ebx
call fcn.0052388c
mov esp, ebp
pop ebp
ret