Function at 0x408bb0
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x49d0d9
mov eax, dword fs:[0]
push eax
sub esp, 0x14
push ebx
push ebp
push esi
push edi
mov eax, dword [0x4d6720]
xor eax, esp
push eax
lea eax, [esp + 0x28]
mov dword fs:[0], eax
xor ebp, ebp
mov dword [esp + 0x20], ebp
mov ebx, dword [esp + 0x38]
push str.REM
mov ecx, ebx
mov dword [esp + 0x34], ebp
call fcn.00403c10
mov eax, dword [esp + 0x40]
push eax
lea ecx, [esp + 0x20]
push ebp
mov esi, 1
push ecx
mov dword [esp + 0x3c], ebp
mov dword [esp + 0x2c], esi
call fcn.00407a10
add esp, 0xc
mov eax, dword [eax]
mov ecx, dword [eax - 0xc]
push ecx
push eax
mov ecx, ebx
mov dword [esp + 0x38], esi
call fcn.00401990
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
mov byte [esp + 0x30], 0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x408c48
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov edi, dword [esp + 0x3c]
cmp edi, ebp
jle 0x408cc4
call fcn.00468b49
xor ecx, ecx
cmp eax, ebp
setne cl
cmp ecx, ebp
jne 0x408c6a
push 0x80004005
call fcn.00401210
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
lea esi, [eax + 0x10]
mov dword [esp + 0x14], esi
mov ecx, dword [ebx]
mov eax, dword [ecx - 0xc]
xor edx, edx
xor ecx, ecx
cmp eax, ebp
mov dword [esp + 0x30], 2
mov dword [esp + 0x24], eax
mov dword [esp + 0x1c], edx
jg 0x408cf8
lea ecx, [esp + 0x14]
push ecx
mov ecx, ebx
call fcn.00401a50
add esi, 0xfffffff0
mov byte [esp + 0x30], 0
lea edx, [esi + 0xc]
or eax, 0xffffffff
lock xadd dword [edx], eax
dec eax
test eax, eax
jg 0x408cc4
mov ecx, dword [esi]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push esi
call eax
push str._r_nREM
push 0x4a80b8
mov ecx, ebx
call fcn.004066b0
mov eax, ebx
mov ecx, dword [esp + 0x28]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret
mov ecx, dword [esp + 0x18]
mov edi, dword [esp + 0x3c]
inc ecx
mov dword [esp + 0x18], ecx
test edx, edx
jl 0x408dee
mov eax, dword [ebx]
cmp edx, dword [eax - 0xc]
jg 0x408dee
cmp ecx, edi
movzx ebp, word [eax + edx*2]
jl 0x408d89
cmp bp, 0x20
je 0x408d31
cmp bp, 9
je 0x408d31
cmp bp, 0xa
je 0x408d31
lea eax, [edi + edi]
cmp ecx, eax
jl 0x408d89
push ebp
lea ecx, [esp + 0x18]
call fcn.00403890
mov esi, dword [esp + 0x14]
mov ebp, dword [esi - 0xc]
mov eax, dword [esi - 8]
mov ecx, 1
sub ecx, dword [esi - 4]
lea edi, [ebp + 1]
sub eax, edi
or eax, ecx
jge 0x408d64
push edi
lea ecx, [esp + 0x18]
call fcn.004015f0
mov esi, dword [esp + 0x14]
mov ecx, 0xa
mov word [esi + ebp*2], cx
test edi, edi
jl 0x408dee
cmp edi, dword [esi - 8]
jg 0x408dee
xor edx, edx
mov dword [esi - 0xc], edi
mov word [esi + edi*2], dx
mov dword [esp + 0x18], edx
mov edx, dword [esp + 0x1c]
jmp 0x408dda
cmp bp, 0xa
jne 0x408d97
mov dword [esp + 0x18], 0
mov ebx, dword [esi - 0xc]
mov eax, dword [esi - 8]
mov ecx, 1
sub ecx, dword [esi - 4]
lea edi, [ebx + 1]
sub eax, edi
or eax, ecx
jge 0x408dc0
push edi
lea ecx, [esp + 0x18]
call fcn.004015f0
mov esi, dword [esp + 0x14]
mov edx, dword [esp + 0x1c]
mov word [esi + ebx*2], bp
test edi, edi
jl 0x408dee
cmp edi, dword [esi - 8]
jg 0x408dee
mov ebx, dword [esp + 0x38]
xor eax, eax
mov dword [esi - 0xc], edi
mov word [esi + edi*2], ax
inc edx
cmp edx, dword [esp + 0x24]
mov dword [esp + 0x1c], edx
jl 0x408cf0
jmp 0x408c97
push 0x80070057
call fcn.00401210
int3