Function at 0x10005860
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x78
mov ebx, dword [ebp + 8]
test byte [0x1001a03c], 8
jne 0x10005b70
mov eax, dword [ebx + 0x20]
mov esi, dword [eax + 0x74]
test esi, esi
je 0x10005eb5
mov ecx, dword [ebp + 0xc]
test ecx, ecx
je 0x10005e5c
mov edx, dword [ebp + 0xc]
cmp dword [edx], 0x50
jne 0x10005e5c
mov edx, dword [eax]
mov dword [ebp - 0x5c], edx
test edx, edx
jne 0x10005ea9
mov edx, dword [eax + 0x68]
test edx, edx
je 0x10005920
mov eax, dword [eax + 0x54]
test eax, eax
jne 0x10005920
test byte [0x1001a03c], 4
jne 0x10005d70
lea ecx, [ebp - 0x3c]
lea edx, [ebp - 0x40]
mov eax, 0x100221d0
call sym._DP_BuildSPCompoundAddr
test eax, eax
je 0x10005e7c
mov eax, dword [ebx]
mov edx, dword [ebp - 0x40]
mov dword [esp + 8], 0
mov dword [esp], ebx
mov dword [esp + 4], edx
call dword [eax + 0x98]
sub esp, 0xc
test eax, eax
js 0x10005d68
mov eax, dword [ebp - 0x40]
mov dword [esp], eax
call dword [sym.imp.ucrtbase.dll_free]
mov eax, dword [ebx + 0x20]
mov dword [eax + 0x54], 1
lea esi, [esi]
mov eax, dword [ebx]
lea edx, [ebp - 0x34]
mov dword [ebp - 0x34], 0x28
mov dword [esp + 8], 0
mov dword [esp + 4], edx
mov dword [esp], ebx
call dword [eax + 0x38]
mov ecx, dword [ebp - 0x10]
mov eax, 0x1388
sub esp, 0xc
test ecx, ecx
cmovne eax, ecx
mov dword [ebp - 0x54], eax
test byte [ebp + 0x1c], 0x20
jne 0x10005bc8
mov eax, dword [ebp + 0xc]
mov edx, 1
mov eax, dword [eax + 0x34]
call sym._DP_DuplicateString.constprop.0
mov dword [ebp - 0x50], eax
test eax, eax
je 0x10005be0
mov eax, dword [ebp + 0x1c]
lea edi, [ebx + 8]
and eax, 0x10
mov dword [ebp - 0x4c], eax
mov eax, dword [ebp + 0xc]
add eax, 0x18
mov dword [ebp - 0x58], eax
lea esi, [esi]
nop
mov eax, dword [ebp - 0x4c]
test eax, eax
jne 0x10005a05
mov dword [esp], edi
call dword [sym.imp.kernel32.dll_EnterCriticalSection]
mov eax, dword [ebx + 0x20]
sub esp, 4
mov eax, dword [eax + 0x10]
mov dword [esp], eax
call sym._NS_InvalidateSessionCache
mov dword [esp], edi
call dword [sym.imp.kernel32.dll_LeaveCriticalSection]
mov eax, dword [ebx + 0x20]
sub esp, 4
add eax, 0x2c
mov dword [esp + 0xc], eax
mov eax, dword [ebp - 0x50]
mov dword [esp + 8], eax
mov eax, dword [ebp + 0x1c]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x58]
mov dword [esp], eax
call sym._NS_SendSessionRequestBroadcast
test eax, eax
js 0x10005da0
mov eax, dword [ebp + 0x10]
mov dword [esp + 4], 0
test eax, eax
cmove eax, dword [ebp - 0x54]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_SleepEx]
sub esp, 8
mov dword [esp], edi
call dword [sym.imp.kernel32.dll_EnterCriticalSection]
mov eax, dword [ebx + 0x20]
sub esp, 4
mov eax, dword [eax + 0x10]
mov dword [esp], eax
call sym._NS_PruneSessionCache
mov eax, dword [ebx + 0x20]
mov eax, dword [eax + 0x10]
mov dword [esp], eax
call sym._NS_ResetSessionEnumeration
mov dword [esp], edi
call dword [sym.imp.kernel32.dll_LeaveCriticalSection]
mov eax, dword [ebx + 0x20]
sub esp, 4
mov eax, dword [eax + 0x10]
mov dword [ebp - 0x44], eax
test byte [0x1001a03c], 1
jne 0x10005b40
mov dword [ebp - 0x48], edi
lea esi, [ebp + 0x10]
jmp 0x10005a84
mov eax, dword [ebp + 0x18]
mov dword [esp + 8], 0
mov dword [esp + 4], esi
mov dword [esp + 0xc], eax
mov dword [esp], edi
call dword [ebp + 0x14]
sub esp, 0x10
test eax, eax
je 0x10005b00
mov eax, dword [ebp - 0x44]
mov dword [esp + 4], 0
mov dword [esp], eax
call sym._NS_WalkSessions
mov edi, eax
test eax, eax
je 0x10005ad0
test byte [0x1001a03c], 8
je 0x10005a60
mov dword [esp + 0xc], str.EnumSessionsCallback2_invoked_n
mov dword [esp + 8], str.DP_InvokeEnumSessionCallbacks
mov dword [esp + 4], 0x1001a03c
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0_1
jmp 0x10005a60
mov eax, dword [ebp + 0x18]
mov edi, dword [ebp - 0x48]
mov dword [esp + 4], esi
mov dword [esp + 8], 1
mov dword [esp + 0xc], eax
mov dword [esp], 0
call dword [ebp + 0x14]
sub esp, 0x10
test eax, eax
jne 0x10005990
lea esi, [esi]
nop
mov esi, dword [ebp - 0x4c]
test esi, esi
je 0x10005b20
mov eax, dword [ebx + 0x20]
mov ecx, dword [eax + 0xc]
test ecx, ecx
jne 0x10005dfa
cmp dword [eax + 4], 0xffffffff
je 0x10005c00
nop
mov eax, dword [ebp - 0x50]
mov dword [esp], eax
call dword [sym.imp.ucrtbase.dll_free]
mov eax, dword [ebp - 0x5c]
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret 0x18
mov dword [esp + 0xc], str.:_not_checking_for_conditions_n
mov dword [esp + 8], str.DP_InvokeEnumSessionCallbacks
mov dword [esp + 4], 0x1001a03c
mov dword [esp], 0
call sym._wine_dbg_log.constprop.0_1
jmp 0x10005a4f
mov eax, dword [ebp + 0x1c]
mov dword [esp + 0xc], str.__p_____p_0x_08lx__p__p_0x_08lx__n
mov dword [esp + 8], str.IDirectPlay4Impl_EnumSessions
mov dword [esp + 0x24], eax
mov eax, dword [ebp + 0x18]
mov dword [esp + 4], 0x1001a03c
mov dword [esp + 0x20], eax
mov eax, dword [ebp + 0x14]
mov dword [esp], 3
mov dword [esp + 0x1c], eax
mov eax, dword [ebp + 0x10]
mov dword [esp + 0x18], eax
mov eax, dword [ebp + 0xc]
mov dword [esp + 0x14], eax
lea eax, [ebx - 0x18]
mov dword [esp + 0x10], eax
call sym._wine_dbg_log.constprop.0_1
jmp 0x10005879
lea eax, [ebx + 0x20]
call sym._DP_KillEnumSessionThread.isra.0
mov eax, dword [ebp - 0x5c]
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret 0x18
mov eax, dword [ebp + 0xc]
mov eax, dword [eax + 0x34]
test eax, eax
je 0x10005976
mov dword [ebp - 0x5c], 0x8007000e
jmp 0x10005b2c
mov dword [eax + 0xc], 1
mov eax, dword [ebx + 0x20]
add eax, 0x2c
mov dword [esp + 0xc], eax
mov eax, dword [ebp - 0x50]
mov dword [esp + 8], eax
mov eax, dword [ebp + 0x1c]
mov dword [esp + 4], eax
mov eax, dword [ebp + 0xc]
add eax, 0x18
mov dword [esp], eax
call sym._NS_SendSessionRequestBroadcast
mov esi, eax
test eax, eax
js 0x10005e18
mov dword [esp + 4], 0x24
mov dword [esp], 1
call dword [sym.imp.ucrtbase.dll_calloc]
mov edi, dword [ebx + 0x20]
mov esi, eax
lea eax, [edi + 0x2c]
mov dword [esi], eax
mov eax, dword [ebp + 0xc]
mov eax, dword [eax + 0x18]
mov dword [esi + 4], eax
mov eax, dword [ebp + 0xc]
mov eax, dword [eax + 0x1c]
mov dword [esi + 8], eax
mov eax, dword [ebp + 0xc]
mov eax, dword [eax + 0x20]
mov dword [esi + 0xc], eax
mov eax, dword [ebp + 0xc]
mov eax, dword [eax + 0x24]
mov dword [esi + 0x10], eax
mov eax, dword [ebp + 0x1c]
mov dword [esi + 0x14], eax
mov eax, dword [ebp + 0x10]
test eax, eax
cmove eax, dword [ebp - 0x54]
mov dword [esi + 0x18], eax
mov eax, dword [ebp - 0x50]
mov dword [esi + 0x1c], eax
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 1
mov dword [esp], 0
call dword [sym.imp.kernel32.dll_CreateEventW]
mov dword [edi + 8], eax
sub esp, 0x10
lea eax, [esi + 0x20]
mov dword [esp + 0x18], 2
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0xffffffff
mov eax, dword [ebx + 0x20]
mov eax, dword [eax + 8]
mov dword [esp], 0xffffffff
mov dword [esp + 4], eax
call dword [sym.imp.kernel32.dll_DuplicateHandle]
sub esp, 0x1c
test eax, eax
movzx eax, byte [0x1001a03c]
je 0x10005dc2
test al, 8
jne 0x10005e33
mov edi, dword [ebx + 0x20]
lea eax, [ebp - 0x38]
mov dword [esp + 0xc], esi
mov dword [esp + 0x14], eax
mov dword [esp + 0x10], 0
mov dword [esp + 8], sym._DP_EnumSessionsSendAsyncRequestThread_4
mov dword [esp + 4], 0
mov dword [esp], 0
call dword [sym.imp.kernel32.dll_CreateThread]
mov dword [edi + 4], eax
mov eax, dword [ebx + 0x20]
sub esp, 0x18
mov edx, dword [eax + 4]
test edx, edx
je 0x10005e68
sub dword [eax + 0xc], 1
jmp 0x10005b2c
mov dword [ebp - 0x5c], eax
jmp 0x10005b2c
mov dword [esp + 0xc], str.Hack_providing_TCP_IP_SP_for_lobby_provider_activated_n
mov dword [esp + 8], str.IDirectPlay4Impl_EnumSessions
mov dword [esp + 4], 0x1001a03c
mov dword [esp], 2
call sym._wine_dbg_log.constprop.0_1
jmp 0x100058c6
mov dword [ebp - 0x44], eax
mov eax, dword [ebp - 0x50]
mov dword [esp], eax
call dword [sym.imp.ucrtbase.dll_free]
mov eax, dword [ebp - 0x44]
mov dword [ebp - 0x5c], eax
mov eax, dword [ebp - 0x5c]
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret 0x18
test al, 2
je 0x10005d0d
mov dword [esp + 0xc], str.Cant_duplicate_thread_killing_handle_n
mov dword [esp + 8], str.IDirectPlay4Impl_EnumSessions
mov dword [esp + 4], 0x1001a03c
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0_1
movzx eax, byte [0x1001a03c]
jmp 0x10005d0d
mov eax, dword [ebp - 0x50]
mov dword [esp], eax
call dword [sym.imp.ucrtbase.dll_free]
mov dword [ebp - 0x5c], 0x8877015e
jmp 0x10005b2c
mov eax, dword [ebx + 0x20]
sub dword [eax + 0xc], 1
mov eax, dword [ebp - 0x50]
mov dword [esp], eax
call dword [sym.imp.ucrtbase.dll_free]
mov dword [ebp - 0x5c], esi
jmp 0x10005b2c
mov dword [esp + 0xc], str.:_creating_EnumSessionsRequest_thread_n
mov dword [esp + 8], str.IDirectPlay4Impl_EnumSessions
mov dword [esp + 4], 0x1001a03c
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0_1
jmp 0x10005d15
mov dword [ebp - 0x5c], 0x80070057
jmp 0x10005b2c
mov eax, dword [ebp - 0x50]
mov dword [esp], eax
call dword [sym.imp.ucrtbase.dll_free]
mov eax, dword [ebx + 0x20]
jmp 0x10005d5c
test byte [0x1001a03c], 2
je 0x10005ea9
mov dword [esp + 0xc], str.Cant_build_compound_addr_n
mov dword [esp + 8], str.IDirectPlay4Impl_EnumSessions
mov dword [esp + 4], 0x1001a03c
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0_1
mov dword [ebp - 0x5c], 0x80004005
jmp 0x10005b2c
mov dword [ebp - 0x5c], 0x88770140
jmp 0x10005b2c