Function at 0x40db20
Capabilities:
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, 0x78
mov eax, dword [ecx]
mov dword [esp], 0
mov dword [ebp - 0x64], eax
call dword [0x41c558]
mov esi, dword [sym.imp.kernel32.dll_CreateFileW]
mov dword [ebp - 0x60], eax
mov eax, dword [0x412394]
sub esp, 4
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0x42000000
mov dword [esp + 0x10], 3
mov dword [esp + 0xc], 0
mov dword [esp + 8], 3
mov dword [esp + 4], 0x100001
mov dword [esp], eax
call esi
sub esp, 0x1c
cmp eax, 0xffffffff
je 0x40de9c
mov ebx, eax
mov eax, dword [0x412398]
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0x42000000
mov dword [esp + 0x10], 3
mov dword [esp + 0xc], 0
mov dword [esp + 8], 3
mov dword [esp + 4], 0x100001
mov dword [esp], eax
call esi
sub esp, 0x1c
mov esi, eax
cmp eax, 0xffffffff
je 0x40de90
mov dword [esp + 0xc], 0
mov edi, dword [sym.imp.kernel32.dll_CreateEventW]
mov dword [esp + 8], 0
mov dword [esp + 4], 0
mov dword [esp], 0
call edi
mov dword [ebp - 0x48], eax
sub esp, 0x10
mov dword [ebp - 0x30], eax
test eax, eax
je 0x40dde8
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0
mov dword [esp], 0
call edi
mov dword [ebp - 0x44], eax
sub esp, 0x10
mov dword [ebp - 0x1c], eax
test eax, eax
je 0x40dde8
mov dword [esp + 8], 0x1000
mov edi, dword [sym.imp.kernel32.dll_HeapAlloc]
mov dword [esp + 4], 0
mov edx, dword fs:[0x18]
mov eax, dword [edx + 0x30]
mov dword [ebp - 0x68], edx
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call edi
mov dword [ebp - 0x5c], eax
sub esp, 0xc
test eax, eax
je 0x40dde8
mov edx, dword [ebp - 0x68]
mov dword [esp + 8], 0x1000
mov dword [esp + 4], 0
mov eax, dword [edx + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call edi
sub esp, 0xc
mov edi, eax
test eax, eax
je 0x40df1e
lea eax, [ebp - 0x40]
mov dword [esp + 0x1c], 0
mov dword [esp + 0x18], eax
mov eax, dword [ebp - 0x5c]
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 1
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0x1000
mov dword [esp + 4], eax
mov dword [esp], ebx
call dword [sym.imp.kernel32.dll_ReadDirectoryChangesW]
sub esp, 0x20
test eax, eax
je 0x40df10
lea eax, [ebp - 0x2c]
mov dword [esp + 0x1c], 0
mov dword [esp + 0x18], eax
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 1
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0x1000
mov dword [esp + 4], edi
mov dword [esp], esi
call dword [sym.imp.kernel32.dll_ReadDirectoryChangesW]
sub esp, 0x20
test eax, eax
je 0x40df10
lea eax, [ebp - 0x48]
mov dword [esp + 0xc], 0xffffffff
mov dword [esp + 8], 0
mov dword [esp + 4], eax
mov dword [esp], 2
call dword [sym.imp.kernel32.dll_WaitForMultipleObjects]
sub esp, 0x10
mov edx, eax
test eax, eax
je 0x40deb8
cmp eax, 1
jne 0x40ddf6
lea eax, [ebp - 0x4c]
mov dword [esp + 0xc], 0
mov dword [esp + 8], eax
lea eax, [ebp - 0x2c]
mov dword [esp + 4], eax
mov dword [esp], esi
call dword [sym.imp.kernel32.dll_GetOverlappedResult]
sub esp, 0x10
test eax, eax
je 0x40dcb0
mov edx, dword [ebp - 0x4c]
test edx, edx
je 0x40dcb0
mov eax, dword [0x412398]
mov edx, edi
call sym._process_changes
test eax, eax
je 0x40dcb0
mov eax, dword [ebp - 0x64]
mov dword [esp + 8], 1
mov dword [esp + 4], 0
mov dword [esp], eax
call dword [sym.imp.user32.dll_InvalidateRect]
sub esp, 0xc
jmp 0x40dcb0
mov dword [ebp - 0x5c], 0
mov edx, 0xe
xor edi, edi
mov dword [ebp - 0x64], edx
mov dword [esp], ebx
mov ebx, dword [sym.imp.kernel32.dll_CloseHandle]
call ebx
sub esp, 4
mov dword [esp], esi
call ebx
mov eax, dword [ebp - 0x48]
sub esp, 4
mov dword [esp], eax
call ebx
mov eax, dword [ebp - 0x44]
sub esp, 4
mov dword [esp], eax
call ebx
mov eax, dword [ebp - 0x5c]
mov esi, dword [sym.imp.kernel32.dll_HeapFree]
sub esp, 4
mov dword [esp + 8], eax
mov dword [esp + 4], 0
mov ebx, dword fs:[0x18]
mov eax, dword [ebx + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call esi
sub esp, 0xc
mov dword [esp + 8], edi
mov dword [esp + 4], 0
mov eax, dword [ebx + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call esi
mov eax, dword [ebp - 0x60]
mov edx, dword [ebp - 0x64]
sub esp, 0xc
test eax, eax
js 0x40de7f
mov dword [ebp - 0x5c], edx
call dword [0x41c568]
mov edx, dword [ebp - 0x5c]
lea esp, [ebp - 0x10]
mov eax, edx
pop ecx
pop ebx
pop esi
pop edi
pop ebp
lea esp, [ecx - 4]
ret 4
mov dword [esp], ebx
call dword [sym.imp.kernel32.dll_CloseHandle]
sub esp, 4
mov eax, dword fs:[0x18]
mov edx, dword [eax + 0x34]
lea esp, [ebp - 0x10]
pop ecx
pop ebx
mov eax, edx
pop esi
pop edi
pop ebp
lea esp, [ecx - 4]
ret 4
lea eax, [ebp - 0x4c]
mov dword [esp + 0xc], 0
mov dword [esp + 8], eax
lea eax, [ebp - 0x40]
mov dword [esp + 4], eax
mov dword [esp], ebx
call dword [sym.imp.kernel32.dll_GetOverlappedResult]
sub esp, 0x10
test eax, eax
je 0x40dcb0
mov ecx, dword [ebp - 0x4c]
test ecx, ecx
je 0x40dcb0
mov edx, dword [ebp - 0x5c]
mov eax, dword [0x412394]
call sym._process_changes
test eax, eax
je 0x40dcb0
jmp 0x40ddc0
mov eax, dword fs:[0x18]
mov edx, dword [eax + 0x34]
jmp 0x40ddf6
mov edx, 0xe
jmp 0x40ddf6