Function at 0x401020
Capabilities:
Get process heap force flags
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x3d0
mov esi, dword [ebp + 0x10]
mov dword [ebp - 0x3dc], 0x30
mov dword [ebp - 0x3d8], 3
mov eax, dword [sym.imp.user32.dll_DefWindowProcW]
mov dword [ebp - 0x3d4], eax
mov dword [ebp - 0x3d0], 0
mov dword [ebp - 0x3cc], 0
mov dword [ebp - 0x3c8], 0
mov dword [ebp - 0x3c4], 0
push 0x7f00
push 0
call dword [sym.imp.user32.dll_LoadCursorW]
mov dword [ebp - 0x3c0], eax
mov dword [ebp - 0x3bc], 6
mov dword [ebp - 0x3b8], 0
mov dword [ebp - 0x3b4], str.class_rundll32
mov dword [ebp - 0x3b0], 0
lea edi, [ebp - 0x3dc]
push edi
call dword [sym.imp.user32.dll_RegisterClassExW]
push 0
push 0
push 0
push 0
push 0
push 0x80000000
push 0
push 0x80000000
push 0x10cf0000
push 0x4030e0
push str.class_rundll32
push 0
call dword [sym.imp.user32.dll_CreateWindowExW]
mov ebx, eax
test byte [section..data], 8
je 0x40111b
mov ecx, esi
call sym._wine_dbgstr_w
sub esp, 0x14
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.CmdLine_s_n
mov dword [esp], 3
call sym._wine_dbg_log
add esp, 0x14
lea ecx, [ebp + 0x10]
call sym._get_next_arg
mov esi, eax
mov dword [ebp - 0x34], 0xffffffff
test eax, eax
je 0x40123d
cmp word [esi], 0
je 0x40123d
test byte [section..data], 8
je 0x40116c
mov ecx, esi
call sym._wine_dbgstr_w
sub esp, 0x14
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.DllName_s_n
mov dword [esp], 3
call sym._wine_dbg_log
add esp, 0x14
push 0x2c
push esi
call dword [sym.imp.ucrtbase.dll_wcschr]
add esp, 8
test eax, eax
je 0x401246
mov ecx, eax
add ecx, 2
mov dword [ebp - 0x20], ecx
mov word [eax], 0
test byte [section..data], 8
je 0x4011bc
mov ecx, dword [ebp - 0x20]
call sym._wine_dbgstr_w
sub esp, 0x14
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.EntryPoint_s_n
mov dword [esp], 3
call sym._wine_dbg_log
add esp, 0x14
push 0
push edi
push 0x104
push 0
push esi
push 0
call dword [sym.imp.kernel32.dll_SearchPathW]
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x34], 0xffffffff
test eax, eax
je 0x401295
mov dword [ebp - 0x48], 0
mov dword [ebp - 0x4c], 0
mov dword [ebp - 0x54], 0
mov dword [ebp - 0x58], 0
mov dword [ebp - 0x64], 0x20
mov dword [ebp - 0x5c], edi
mov dword [ebp - 0x50], 0x7b
mov dword [ebp - 0x60], 8
lea eax, [ebp - 0x64]
push eax
call dword [sym.imp.kernel32.dll_CreateActCtxW]
cmp eax, 0xffffffff
je 0x401263
mov edi, eax
lea eax, [ebp - 0x44]
push eax
push edi
call dword [sym.imp.kernel32.dll_ActivateActCtx]
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x34], edi
jmp 0x401295
xor eax, eax
xor edi, edi
jmp 0x401643
lea ecx, [ebp + 0x10]
call sym._get_next_arg
mov dword [ebp - 0x20], eax
test byte [section..data], 8
jne 0x401196
jmp 0x4011bc
test byte [section..data], 8
je 0x401295
lea ecx, [ebp - 0x3dc]
call sym._wine_dbgstr_w
sub esp, 0x14
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.No_manifest_at_ID_123_in__s_n
mov dword [esp], 3
call sym._wine_dbg_log
add esp, 0x14
push esi
call dword [sym.imp.kernel32.dll_LoadLibraryW]
mov dword [ebp - 0x28], eax
test eax, eax
mov dword [ebp - 0x18], ebx
je 0x4012e2
mov eax, dword [ebp - 0x20]
cmp word [eax], 0x23
jne 0x40135d
add eax, 2
push 0xa
push 0
push eax
call dword [sym.imp.ucrtbase.dll_wcstol]
add esp, 0xc
test eax, eax
jle 0x4015fe
mov edi, 1
push eax
push dword [ebp - 0x28]
call dword [sym.imp.kernel32.dll_GetProcAddress]
mov ebx, eax
jmp 0x401559
push 0
push 0
push 0
push 0
push 0xffffffffffffffff
push esi
push 0
push 0
call dword [sym.imp.kernel32.dll_WideCharToMultiByte]
mov ebx, eax
mov eax, dword fs:[0x18]
mov dword [ebp - 0x1d4], eax
mov eax, dword [ebp - 0x1d4]
mov eax, dword [eax + 0x30]
push ebx
push 0
push dword [eax + 0x18]
call dword [sym.imp.kernel32.dll_HeapAlloc]
test eax, eax
je 0x401411
mov edi, eax
push 0
push 0
push ebx
push eax
push 0xffffffffffffffff
push esi
push 0
push 0
call dword [sym.imp.kernel32.dll_WideCharToMultiByte]
push 0x4031e4
call dword [sym.imp.kernel32.dll_GetModuleHandleW]
push 0x23
push eax
call dword [sym.imp.kernel32.dll_GetProcAddress]
test eax, eax
je 0x4013e8
push edi
call eax
mov ebx, eax
jmp 0x4013ea
push 0
push 0
push 0
push 0
push 0xffffffffffffffff
push eax
push 0
push 0
call dword [sym.imp.kernel32.dll_WideCharToMultiByte]
mov ebx, eax
lea ecx, [eax + 1]
mov eax, dword fs:[0x18]
mov dword [ebp - 0x1d4], eax
mov eax, dword [ebp - 0x1d4]
mov eax, dword [eax + 0x30]
push ecx
push 0
push dword [eax + 0x18]
call dword [sym.imp.kernel32.dll_HeapAlloc]
test eax, eax
je 0x4015fe
mov edi, eax
push 0
push 0
push ebx
push eax
push 0xffffffffffffffff
push dword [ebp - 0x20]
push 0
push 0
call dword [sym.imp.kernel32.dll_WideCharToMultiByte]
push edi
call dword [sym.imp.ucrtbase.dll_strlen]
add esp, 4
mov word [edi + eax], 0x57
push edi
mov ebx, dword [ebp - 0x28]
push ebx
call dword [sym.imp.kernel32.dll_GetProcAddress]
test eax, eax
je 0x4014f6
mov ecx, eax
mov dword [ebp - 0x24], 1
jmp 0x401533
xor ebx, ebx
mov eax, dword fs:[0x18]
mov dword [ebp - 0x1d4], eax
mov eax, dword [ebp - 0x1d4]
mov eax, dword [eax + 0x30]
push edi
push 0
push dword [eax + 0x18]
call dword [sym.imp.kernel32.dll_HeapFree]
cmp bx, 0x20
ja 0x40144e
xor eax, eax
test byte [section..data], 2
je 0x401443
mov ecx, esi
call sym._wine_dbgstr_w
sub esp, 0x14
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.Unable_to_load__s_n
mov dword [esp], 1
call sym._wine_dbg_log
xor eax, eax
add esp, 0x14
mov ebx, dword [ebp - 0x18]
mov edi, dword [ebp - 0x1c]
jmp 0x401643
mov dword [ebp - 0x24], ebx
push 0
push 0
push 0
push 0
push 0xffffffffffffffff
push dword [ebp - 0x20]
push 0
push 0
call dword [sym.imp.kernel32.dll_WideCharToMultiByte]
mov ebx, eax
mov eax, dword fs:[0x18]
mov dword [ebp - 0x1d4], eax
mov eax, dword [ebp - 0x1d4]
mov eax, dword [eax + 0x30]
push ebx
push 0
push dword [eax + 0x18]
call dword [sym.imp.kernel32.dll_HeapAlloc]
test eax, eax
je 0x4015fe
mov edi, eax
push 0
push 0
push ebx
push eax
push 0xffffffffffffffff
push dword [ebp - 0x20]
push 0
push 0
call dword [sym.imp.kernel32.dll_WideCharToMultiByte]
push 0x4031e4
call dword [sym.imp.kernel32.dll_GetModuleHandleW]
push 0x25
push eax
call dword [sym.imp.kernel32.dll_GetProcAddress]
mov ebx, 0
test eax, eax
je 0x4014d1
movzx ecx, word [ebp - 0x24]
push edi
push ecx
call eax
mov ebx, eax
mov eax, dword fs:[0x18]
mov dword [ebp - 0x1d4], eax
mov eax, dword [ebp - 0x1d4]
mov eax, dword [eax + 0x30]
push edi
push 0
push dword [eax + 0x18]
call dword [sym.imp.kernel32.dll_HeapFree]
xor edi, edi
jmp 0x401559
push edi
call dword [sym.imp.ucrtbase.dll_strlen]
add esp, 4
mov byte [eax + edi - 1], 0x41
push edi
push ebx
call dword [sym.imp.kernel32.dll_GetProcAddress]
mov dword [ebp - 0x24], 0
test eax, eax
je 0x40151c
mov ecx, eax
jmp 0x401533
push edi
call dword [sym.imp.ucrtbase.dll_strlen]
add esp, 4
mov byte [eax + edi - 1], 0
push edi
push ebx
call dword [sym.imp.kernel32.dll_GetProcAddress]
mov ebx, eax
mov eax, dword fs:[0x18]
mov dword [ebp - 0x1d4], eax
mov eax, dword [ebp - 0x1d4]
mov eax, dword [eax + 0x30]
push edi
push 0
push dword [eax + 0x18]
call dword [sym.imp.kernel32.dll_HeapFree]
mov edi, dword [ebp - 0x24]
test ebx, ebx
je 0x4015fe
lea eax, [ebp - 0xa8]
push eax
call dword [sym.imp.kernel32.dll_GetStartupInfoW]
test byte [ebp - 0x7c], 1
jne 0x40157a
mov word [ebp - 0x78], 0xa
mov ecx, dword [ebp + 8]
test edi, edi
mov dword [ebp - 0x24], ebx
je 0x4016a5
test byte [section..data], 8
mov edi, dword [ebp + 0x10]
je 0x4015e6
movzx eax, word [ebp - 0x78]
mov dword [ebp - 0x14], eax
mov ecx, edi
call sym._wine_dbgstr_w
mov ebx, eax
mov ecx, dword [ebp - 0x20]
call sym._wine_dbgstr_w
sub esp, 0x24
mov ecx, dword [ebp - 0x14]
mov dword [esp + 0x20], ecx
mov dword [esp + 0x1c], ebx
mov ecx, dword [ebp + 8]
mov dword [esp + 0x18], ecx
mov ecx, dword [ebp - 0x18]
mov dword [esp + 0x14], ecx
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.Calling__s___p__p__s__d__n
mov dword [esp], 3
call sym._wine_dbg_log
mov ecx, dword [ebp + 8]
add esp, 0x24
movzx eax, word [ebp - 0x78]
push eax
push edi
push ecx
mov ebx, dword [ebp - 0x18]
push ebx
push dword [ebp - 0x24]
call sym._call_entry_point
add esp, 0x14
jmp 0x40163d
test byte [section..data], 2
je 0x40163a
mov ecx, esi
call sym._wine_dbgstr_w
mov edi, eax
mov ecx, dword [ebp - 0x20]
call sym._wine_dbgstr_w
sub esp, 0x18
mov dword [esp + 0x14], edi
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.Unable_to_find_the_entry_point__s_in__s_n
mov dword [esp], 1
call sym._wine_dbg_log
add esp, 0x18
mov ebx, dword [ebp - 0x18]
mov edi, dword [ebp - 0x1c]
mov eax, dword [ebp - 0x28]
test ebx, ebx
je 0x401652
push ebx
mov ebx, eax
call dword [sym.imp.user32.dll_DestroyWindow]
mov eax, ebx
test eax, eax
je 0x40165d
push eax
call dword [sym.imp.kernel32.dll_FreeLibrary]
test edi, edi
je 0x40166c
push dword [ebp - 0x44]
push 0
call dword [sym.imp.kernel32.dll_DeactivateActCtx]
push dword [ebp - 0x34]
call dword [sym.imp.kernel32.dll_ReleaseActCtx]
mov eax, dword fs:[0x18]
mov dword [ebp - 0x1d4], eax
mov eax, dword [ebp - 0x1d4]
mov eax, dword [eax + 0x30]
push esi
push 0
push dword [eax + 0x18]
call dword [sym.imp.kernel32.dll_HeapFree]
xor eax, eax
add esp, 0x3d0
pop esi
pop edi
pop ebx
pop ebp
ret 0x10
mov ebx, dword [ebp + 0x10]
push 0
push 0
push 0
push 0
push 0xffffffffffffffff
push ebx
push 0
push 0
call dword [sym.imp.kernel32.dll_WideCharToMultiByte]
mov edi, eax
mov eax, dword fs:[0x18]
mov dword [ebp - 0x1d4], eax
mov eax, dword [ebp - 0x1d4]
mov eax, dword [eax + 0x30]
push edi
push 0
push dword [eax + 0x18]
call dword [sym.imp.kernel32.dll_HeapAlloc]
test eax, eax
je 0x40163a
push 0
push 0
push edi
mov dword [ebp - 0x30], eax
push eax
push 0xffffffffffffffff
push ebx
push 0
push 0
call dword [sym.imp.kernel32.dll_WideCharToMultiByte]
test byte [section..data], 8
mov ebx, dword [ebp - 0x18]
je 0x401948
movzx eax, word [ebp - 0x78]
mov dword [ebp - 0x40], eax
mov eax, dword [ebp - 0x30]
cmp eax, 0xffff
ja 0x401736
movzx eax, ax
sub esp, 8
mov dword [esp + 4], eax
call sym._wine_dbg_sprintf
add esp, 8
jmp 0x40190a
push 0xffffffffffffffff
push eax
call dword [sym.imp.kernel32.dll_IsBadStringPtrA]
mov edi, str._invalid_
test eax, eax
jne 0x40190c
xor edi, edi
mov eax, dword [ebp - 0x30]
cmp byte [eax + edi], 0
lea edi, [edi + 1]
jne 0x401751
mov byte [ebp - 0x1d4], 0x22
cmp edi, 1
jne 0x401778
lea ecx, [ebp - 0x1d2]
mov byte [ebp - 0x1d3], 0x22
jmp 0x4018f8
lea ecx, [ebp - 0x1d3]
mov edx, 1
mov ebx, eax
mov dword [ebp - 0x10], ecx
mov dword [ebp - 0x14], edx
movzx ecx, byte [ebx]
movzx eax, cl
mov byte [ebp - 0x29], cl
lea edx, [eax - 9]
cmp edx, 0x19
ja case.default.0x40179c
jmp dword [edx*4 + section..rdata]
mov eax, dword [ebp - 0x10]
mov byte [eax], 0x5c
mov edx, dword [ebp - 0x14]
lea eax, [ebp - 0x1d4]
mov byte [edx + eax + 1], 0x74
add edx, 2
jmp 0x4018c1
cmp eax, 0x5c
jne case.0x40179c.11
mov eax, dword [ebp - 0x10]
mov byte [eax], 0x5c
mov edx, dword [ebp - 0x14]
lea eax, [ebp - 0x1d4]
mov byte [edx + eax + 1], 0x5c
add edx, 2
jmp 0x4018c1
cmp cl, 0x1f
ja 0x401880
mov ecx, dword [ebp - 0x10]
mov byte [ecx], 0x5c
mov edx, dword [ebp - 0x14]
lea ecx, [ebp - 0x1d4]
mov byte [edx + ecx + 1], pe_nt_image_headers32
mov ecx, eax
shr ecx, 4
movzx ecx, byte [ecx + str.0123456789abcdefr]
mov dword [ebp - 0x10], ebx
lea ebx, [ebp - 0x1d4]
mov byte [edx + ebx + 2], cl
mov ebx, dword [ebp - 0x10]
and eax, 0xf
movzx eax, byte [eax + str.0123456789abcdefr]
lea ecx, [ebp - 0x1d4]
mov byte [edx + ecx + 3], al
add edx, 4
jmp 0x4018c1
mov eax, dword [ebp - 0x10]
mov byte [eax], 0x5c
mov edx, dword [ebp - 0x14]
lea eax, [ebp - 0x1d4]
mov byte [edx + eax + 1], 0x6e
add edx, 2
jmp 0x4018c1
mov eax, dword [ebp - 0x10]
mov byte [eax], 0x5c
mov edx, dword [ebp - 0x14]
lea eax, [ebp - 0x1d4]
mov byte [edx + eax + 1], 0x72
add edx, 2
jmp 0x4018c1
mov eax, dword [ebp - 0x10]
mov byte [eax], 0x5c
mov edx, dword [ebp - 0x14]
lea eax, [ebp - 0x1d4]
mov byte [edx + eax + 1], 0x22
add edx, 2
jmp 0x4018c1
cmp cl, 0x7f
jb 0x4018b8
push 1
lea eax, [ebp - 0x29]
push eax
lea eax, [ebp - 0x3c]
push eax
push 2
lea eax, [ebp - 0x36]
push eax
call dword [sym.imp.ntdll.dll_RtlMultiByteToUnicodeN]
push 2
lea eax, [ebp - 0x36]
push eax
lea eax, [ebp - 0x3c]
push eax
push 4
push dword [ebp - 0x10]
call dword [sym.imp.ntdll.dll_RtlUnicodeToUTF8N]
mov edx, dword [ebp - 0x14]
add edx, dword [ebp - 0x3c]
jmp 0x4018c1
mov edx, dword [ebp - 0x14]
inc edx
mov eax, dword [ebp - 0x10]
mov byte [eax], cl
dec edi
lea ecx, [edx + ebp]
add ecx, 0xfffffe2c
cmp edi, 2
jl 0x4018dd
inc ebx
cmp edx, 0x124
jl 0x401785
mov byte [ecx], 0x22
cmp edi, 3
mov ebx, dword [ebp - 0x18]
jl 0x4018f7
mov word [ecx + 1], 0x2e2e
mov byte [ecx + 3], 0x2e
add ecx, 4
jmp 0x4018f8
inc ecx
mov byte [ecx], 0
lea eax, [ebp - 0x1d4]
push eax
call sym.___wine_dbg_strdup
add esp, 4
mov edi, eax
mov ecx, dword [ebp - 0x20]
call sym._wine_dbgstr_w
sub esp, 0x24
mov ecx, dword [ebp - 0x40]
mov dword [esp + 0x20], ecx
mov dword [esp + 0x1c], edi
mov ecx, dword [ebp + 8]
mov dword [esp + 0x18], ecx
mov dword [esp + 0x14], ebx
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.Calling__s___p__p__s__d__n
mov dword [esp], 3
call sym._wine_dbg_log
add esp, 0x24
cmp dword [ebp - 0x28], 0
je 0x40196d
movzx eax, word [ebp - 0x78]
push eax
mov edi, dword [ebp - 0x30]
push edi
push dword [ebp + 8]
push ebx
push dword [ebp - 0x24]
call sym._call_entry_point
mov edx, edi
add esp, 0x14
mov edi, dword [ebp - 0x1c]
jmp 0x4019ad
push str.shell32.dll
call dword [sym.imp.kernel32.dll_LoadLibraryW]
test eax, eax
mov edi, dword [ebp - 0x1c]
je 0x40198f
push 0x7a
push eax
call dword [sym.imp.kernel32.dll_GetProcAddress]
mov dword [0x404038], eax
jmp 0x401994
mov eax, dword [0x404038]
test eax, eax
mov edx, dword [ebp - 0x30]
je 0x4019ad
movzx ecx, word [ebp - 0x78]
push ecx
push edx
push dword [ebp + 8]
push ebx
push dword [ebp - 0x24]
call eax
mov edx, dword [ebp - 0x30]
mov eax, dword fs:[0x18]
mov dword [ebp - 0x1d4], eax
mov eax, dword [ebp - 0x1d4]
mov eax, dword [eax + 0x30]
push edx
push 0
push dword [eax + 0x18]
call dword [sym.imp.kernel32.dll_HeapFree]
jmp 0x401640