Function at 0x408440
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x54f460
mov eax, dword fs:[0]
push eax
sub esp, 0x18
push ebx
push esi
push edi
mov eax, dword [0x5a5784]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
push str._SEARCH_CDeviceSearchOperation::DoUnicastSearch__._n
push 0x40000
call fcn.0041abf0
mov eax, dword [ebp + 8]
mov ebx, dword [eax + 0x2c]
sub ebx, dword [eax + 0x28]
xor esi, esi
sar ebx, 2
add esp, 8
cmp ebx, esi
jne 0x4084b6
push esi
push str._SEARCH__error__DoUnicastSearch___end._m_vecUnicastIPv4.size:__d._n
push 0x80000
call fcn.0041abf0
add esp, 0xc
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov dword [ebp - 0x24], esi
mov dword [ebp - 0x1c], esi
mov dword [ebp - 0x18], esi
mov dword [ebp - 0x14], 0x28
cmp ebx, 0x28
jg 0x4084ce
mov dword [ebp - 0x14], ebx
push 0x5ad604
call dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
mov eax, dword [ebp - 0x14]
xor ecx, ecx
mov edx, 4
mul edx
seto cl
mov dword [ebp - 4], esi
neg ecx
or ecx, eax
push ecx
call fcn.00430e26
mov edi, eax
xor ecx, ecx
add esp, 4
mov eax, ebx
mov edx, 8
mul edx
seto cl
mov dword [ebp - 0x24], edi
neg ecx
or ecx, eax
push ecx
call fcn.00430e26
mov esi, eax
xor ecx, ecx
add esp, 4
mov eax, ebx
mov edx, 4
mul edx
seto cl
mov dword [ebp - 0x1c], esi
neg ecx
or ecx, eax
push ecx
call fcn.00430e26
mov ecx, eax
add esp, 4
xor eax, eax
mov dword [ebp - 0x18], ecx
mov dword [ebp - 0x20], eax
cmp eax, ebx
jge 0x40855a
mov edx, dword [ebp + 8]
mov dword [ecx + eax*4], 0
mov dword [esi + eax*8 + 4], ecx
mov dword [esi + eax*8], edx
inc eax
jmp 0x408542
xor ebx, ebx
lea esp, [esp]
mov eax, dword [ebp - 0x14]
cmp ebx, eax
jge 0x4085fd
push 0
push 0
lea eax, [esi + ebx*8]
push eax
push 0x409530
push 0
push 0
call fcn.00525509
add esp, 0x18
mov dword [edi + ebx*4], eax
test eax, eax
jne 0x4085f4
push ebx
push str._SEARCH__error__unicast_search_start_failed_in_Threads___d_._n
push 0x80000
call fcn.0041abf0
lea eax, [ebx - 1]
add esp, 0xc
test eax, eax
jle 0x4085ca
push 0xffffffffffffffff
push 1
push edi
push eax
call dword [sym.imp.KERNEL32.dll_WaitForMultipleObjects]
xor esi, esi
lea eax, [ebx - 1]
cmp esi, eax
jge 0x4085c7
mov ecx, dword [edi + esi*4]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
inc esi
jmp 0x4085b3
mov esi, dword [ebp - 0x1c]
test edi, edi
je 0x4085d7
push edi
call fcn.00430e1b
add esp, 4
test esi, esi
je 0x4085e4
push esi
call fcn.00430e1b
add esp, 4
mov eax, dword [ebp - 0x18]
test eax, eax
je 0x4085f4
push eax
call fcn.00430e1b
add esp, 4
inc dword [ebp - 0x20]
inc ebx
jmp 0x408560
push eax
push str._SEARCH_UnicastSearch_start_with___d__Threads._n
push 0x80000
call fcn.0041abf0
mov eax, dword [ebp - 0x14]
add esp, 0xc
cmp eax, dword [ebp - 0x20]
jne 0x40864f
test edi, edi
je 0x408628
push 0xffffffffffffffff
push 1
push edi
push eax
call dword [sym.imp.KERNEL32.dll_WaitForMultipleObjects]
xor esi, esi
lea ebx, [ebx]
cmp esi, dword [ebp - 0x14]
jge 0x408649
mov edx, dword [edi + esi*4]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [edi + esi*4], 0
inc esi
jmp 0x408630
mov esi, dword [ebp - 0x1c]
mov eax, dword [ebp - 0x14]
push eax
push str._SEARCH_Unicast_Search_end_with___d__Threads._n
push 0x80000
call fcn.0041abf0
mov eax, dword [ebp - 0x18]
add esp, 0xc
push eax
call fcn.00430e1b
push esi
call fcn.00430e1b
push edi
call fcn.00430e1b
add esp, 0xc
mov dword [ebp - 4], 0xffffffff
push 0x5ad604
call dword [sym.imp.KERNEL32.dll_DeleteCriticalSection]
mov ecx, dword [ebp + 8]
push ecx
call fcn.00408710
push str._SEARCH_CDeviceSearchOperation::DoUnicastSearch___end._n
push 0x80000
call fcn.0041abf0
add esp, 8
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4