Function at 0x40237a
Capabilities:
Access peb ldr_data
Get process heap flags

Disassembly:
lea ecx, [esp + 4]
and esp, 0xfffffff0
push dword [ecx - 4]
push ebp
mov ebp, esp
push edi
push esi
push ebx
push ecx
sub esp, 0x38
mov eax, dword [ecx + 8]
test byte [0x4090c0], 8
mov edi, dword [ecx + 4]
mov esi, dword [ecx + 0xc]
mov dword [ebp - 0x1c], eax
mov ebx, dword [ecx + 0x10]
jne 0x4024f8
mov dword [esp], 0x4090a0
call dword [sym.imp.kernel32.dll_EnterCriticalSection]
mov eax, dword [0x4090b8]
sub esp, 4
jmp 0x4023cb
mov ecx, dword [eax + 0x14]
mov edx, eax
mov eax, dword [eax]
cmp ecx, edi
je 0x4023f8
cmp eax, 0x4090b8
jne 0x4023c0
mov dword [esp], 0x4090a0
mov ebx, 0x80070057
call dword [sym.imp.kernel32.dll_LeaveCriticalSection]
mov eax, ebx
sub esp, 4
lea esp, [ebp - 0x10]
pop ecx
pop ebx
pop esi
pop edi
pop ebp
lea esp, [ecx - 4]
ret
mov dword [ebp - 0x20], edx
mov ecx, dword [edx + 4]
mov dword [eax + 4], ecx
mov eax, dword [edx]
mov dword [ecx], eax
mov dword [esp], 0x4090a0
call dword [sym.imp.kernel32.dll_LeaveCriticalSection]
mov edx, dword [ebp - 0x20]
mov ecx, dword fs:[0x18]
mov dword [ebp - 0x24], ecx
mov edi, dword [sym.imp.kernel32.dll_HeapAlloc]
mov eax, dword [edx + 8]
sub esp, 4
mov eax, dword [eax]
add eax, 4
mov dword [esp + 8], eax
xor eax, eax
mov dword [esp + 4], eax
mov eax, dword [ecx + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call edi
mov edx, dword [ebp - 0x20]
mov ecx, dword [ebp - 0x24]
mov dword [esi], eax
sub esp, 0xc
mov eax, dword [edx + 0xc]
mov eax, dword [eax]
add eax, 4
mov dword [esp + 8], eax
xor eax, eax
mov dword [esp + 4], eax
mov eax, dword [ecx + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call edi
mov edx, dword [ebp - 0x20]
mov dword [ebx], eax
sub esp, 0xc
test eax, eax
mov ecx, dword [esi]
je 0x402530
test ecx, ecx
je 0x402530
mov eax, dword [edx + 8]
mov eax, dword [eax]
mov dword [ecx], eax
mov esi, dword [esi]
mov eax, dword [edx + 8]
mov dword [ebp - 0x20], esi
mov ecx, dword [esi]
lea edi, [esi + 4]
lea esi, [eax + 4]
cmp ecx, 8
jae 0x4025b7
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [edx + 0xc]
mov eax, dword [ebx]
mov ecx, dword [ecx]
mov dword [eax], ecx
mov eax, dword [ebx]
mov ebx, dword [edx + 0xc]
mov ecx, dword [eax]
lea edi, [eax + 4]
lea esi, [ebx + 4]
mov dword [ebp - 0x20], ecx
cmp ecx, 8
jae 0x40257f
mov ecx, dword [ebp - 0x20]
xor ebx, ebx
rep movsb byte es:[edi], byte [esi]
lock dec dword [edx + 0x20]
je 0x4025f0
mov eax, dword [ebp - 0x1c]
mov dword [eax], 0
lea esp, [ebp - 0x10]
mov eax, ebx
pop ecx
pop ebx
pop esi
pop edi
pop ebp
lea esp, [ecx - 4]
ret
mov edx, str._ld_n
mov ecx, str.IrotRevoke
mov dword [esp + 0x10], edi
mov eax, 0x4090c0
mov dword [esp + 0xc], edx
mov dword [esp + 8], ecx
mov dword [esp + 4], eax
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0_1
jmp 0x4023a0
mov dword [esp + 8], ecx
xor eax, eax
mov esi, dword [sym.imp.kernel32.dll_HeapFree]
mov dword [esp + 4], eax
mov edi, dword fs:[0x18]
mov dword [ebp - 0x20], edx
mov eax, dword [edi + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call esi
mov eax, dword [ebx]
mov ebx, 0x8007000e
sub esp, 0xc
mov dword [esp + 8], eax
xor eax, eax
mov dword [esp + 4], eax
mov eax, dword [edi + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call esi
mov edx, dword [ebp - 0x20]
sub esp, 0xc
jmp 0x4024d2
test edi, 1
jne 0x4026bd
test edi, 2
jne 0x4026a7
test edi, 4
je 0x4024cb
mov eax, dword [esi]
add edi, 4
add esi, 4
mov dword [edi - 4], eax
sub dword [ebp - 0x20], 4
jmp 0x4024cb
test edi, 1
jne 0x40268c
test edi, 2
jne 0x402677
test edi, 4
je 0x4024a7
mov eax, dword [esi]
add edi, 4
add esi, 4
sub ecx, 4
mov dword [edi - 4], eax
jmp 0x4024a7
mov dword [ebp - 0x20], edx
mov eax, dword [edx + 8]
mov edi, dword fs:[0x18]
mov esi, dword [sym.imp.kernel32.dll_HeapFree]
mov dword [esp + 8], eax
xor eax, eax
mov dword [esp + 4], eax
mov eax, dword [edi + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call esi
mov edx, dword [ebp - 0x20]
mov eax, dword [edx + 0xc]
xor edx, edx
sub esp, 0xc
mov dword [esp + 4], edx
mov dword [esp + 8], eax
mov eax, dword [edi + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call esi
mov edx, dword [ebp - 0x20]
xor ecx, ecx
mov eax, dword [edx + 0x10]
sub esp, 0xc
mov dword [esp + 4], ecx
mov dword [esp + 8], eax
mov eax, dword [edi + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call esi
mov edx, dword [ebp - 0x20]
xor eax, eax
sub esp, 0xc
mov dword [esp + 8], edx
mov dword [esp + 4], eax
mov eax, dword [edi + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call esi
sub esp, 0xc
jmp 0x4024dc
movzx eax, word [esi]
add edi, 2
add esi, 2
sub ecx, 2
mov word [edi - 2], ax
jmp 0x4025cf
mov edi, dword [ebp - 0x20]
mov esi, eax
dec ecx
movzx eax, byte [eax + 4]
add esi, 5
lea edi, [edi + 5]
mov byte [ebp - 0x24], al
mov byte [edi - 1], al
jmp 0x4025c3
movzx eax, word [esi]
add edi, 2
add esi, 2
mov word [edi - 2], ax
sub dword [ebp - 0x20], 2
jmp 0x402597
movzx ecx, byte [ebx + 4]
lea edi, [eax + 5]
lea esi, [ebx + 5]
mov byte [eax + 4], cl
dec dword [ebp - 0x20]
jmp 0x40258b