Function at 0x4d7b10
Capabilities:
Create thread

Disassembly:
sub esp, 0x14
push ebx
push ebp
push esi
push edi
push 0x50f05c
mov esi, ecx
call dword [sym.imp.KERNEL32.dll_InterlockedIncrement]
mov ecx, dword [esp + 0x30]
mov edx, dword [esp + 0x34]
mov edi, dword [esp + 0x40]
xor ebx, ebx
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0x2c]
mov dword [esi], eax
mov eax, dword [esp + 0x3c]
mov dword [esi + 4], ecx
mov ecx, dword [esp + 0x38]
mov dword [esi + 8], edx
mov dword [esi + 0x64], ebx
mov dword [esi + 0x68], ebx
mov dword [esi + 0x6c], ebx
mov dword [esi + 0x70], ebx
mov dword [esi + 0x74], ebx
mov dword [esi + 0x78], eax
mov dword [esi + 0x7c], ebx
mov dword [esi + 0x80], ebx
mov dword [esi + 0x84], ecx
mov dword [esi + 0x88], ebx
mov dword [esi + 0x8c], ebx
mov dword [esi + 0x90], ebx
mov dword [esi + 0x94], ebx
mov byte [esi + 0x98], bl
mov dword [esi + 0xb4], ebx
mov dword [esi + 0xb8], ebx
mov dword [esi + 0xbc], ebx
mov dword [esi + 0xc0], ebx
mov dword [esi + 0xc4], ebx
mov byte [esi + 0xc8], bl
mov byte [esi + 0xc9], bl
cmp edi, ebx
jne 0x4d7bc1
cmp dword [esp + 0x44], ebx
je 0x4d7c49
push 0x34c
xor ebp, ebp
call fcn.004b383b
add esp, 4
cmp edi, ebx
je 0x4d7beb
cmp eax, ebx
je 0x4d7c0a
mov edx, dword [esp + 0x48]
mov ecx, dword [esi + 0x78]
push edx
push ecx
push edi
mov ecx, eax
call fcn.004d83c0
jmp 0x4d7c04
cmp eax, ebx
je 0x4d7c0a
mov edx, dword [esp + 0x48]
mov ecx, dword [esi + 0x78]
push edx
mov edx, dword [esp + 0x48]
push ecx
push edx
mov ecx, eax
call fcn.004d82f0
cmp eax, ebx
je 0x4d7c0a
mov ebp, eax
mov ecx, ebp
call fcn.004d82c0
test al, al
je 0x4d7c35
mov edi, dword [esi + 0xc]
cmp edi, ebp
je 0x4d7c49
cmp edi, ebx
je 0x4d7c30
mov ecx, edi
call fcn.004d8360
push edi
call fcn.004b3716
add esp, 4
mov dword [esi + 0xc], ebp
jmp 0x4d7c49
cmp ebp, ebx
je 0x4d7c49
mov ecx, ebp
call fcn.004d8360
push ebp
call fcn.004b3716
add esp, 4
cmp dword [esi + 0xc], ebx
jne 0x4d7d14
lea eax, [esi + 0x9c]
push eax
call dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
mov edi, dword [sym.imp.KERNEL32.dll_CreateSemaphoreW]
push ebx
push 1
push ebx
push ebx
call edi
push ebx
push 1
push ebx
push ebx
mov dword [esi + 0xb4], eax
call edi
mov dword [esi + 0xb8], eax
cmp eax, ebx
je 0x4d7ca9
cmp dword [esi + 0xb4], ebx
je 0x4d7ca9
lea ecx, [esp + 0x30]
push ecx
push ebx
push esi
push 0x4d6e90
push 0x10000
push ebx
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov dword [esi + 0x94], eax
mov edi, dword [sym.imp.KERNEL32.dll_LoadLibraryW]
push str.dbghelp.dll
call edi
mov ebp, dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [esi + 0x70], eax
cmp eax, ebx
je 0x4d7cce
push str.MiniDumpWriteDump
push eax
call ebp
mov dword [esi + 0x74], eax
push str.rpcrt4.dll
call edi
mov dword [esi + 0x7c], eax
cmp eax, ebx
je 0x4d7cea
push str.UuidCreate
push eax
call ebp
mov dword [esi + 0x80], eax
mov edx, dword [esp + 0x28]
push 0xffffffffffffffff
push ebx
lea edi, [esi + 0x10]
push edx
mov ecx, edi
call fcn.00401fb0
cmp dword [edi + 0x18], 8
jb 0x4d7d07
mov edi, dword [edi + 4]
jmp 0x4d7d0a
add edi, 4
mov ecx, esi
mov dword [esi + 0x64], edi
call fcn.004d71e0
mov eax, dword [esi + 0xe0]
mov edx, dword [esi + 0xcc]
lea ecx, [esi + 0xcc]
lea edi, [esp + 0x14]
push edi
push eax
push edx
mov dword [esp + 0x20], ebx
mov dword [esp + 0x24], ebx
mov dword [esp + 0x28], ebx
call fcn.004d7390
cmp dword [esp + 0x10], 1
jne 0x4d7d50
push 0x50f03c
call dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
cmp dword [esp + 0x38], ebx
je 0x4d7df1
push 0x50f03c
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [0x50f054]
cmp eax, ebx
jne 0x4d7d8c
push 0x18
call fcn.004b383b
add esp, 4
cmp eax, ebx
je 0x4d7d85
mov ecx, eax
call fcn.004d78c0
jmp 0x4d7d87
xor eax, eax
mov dword [0x50f054], eax
lea ecx, [esp + 0x2c]
push ecx
mov ecx, eax
mov dword [esp + 0x30], esi
call fcn.004d7aa0
mov bl, byte [esp + 0x38]
test bl, 1
je 0x4d7db6
push 0x4d79f0
call dword [sym.imp.KERNEL32.dll_SetUnhandledExceptionFilter]
mov dword [esi + 0x88], eax
test bl, 2
je 0x4d7dce
push 0x4d7620
call fcn.004b3c1f
add esp, 4
mov dword [esi + 0x8c], eax
test bl, 4
je 0x4d7de6
push 0x4d77b0
call fcn.004b40cd
add esp, 4
mov dword [esi + 0x90], eax
push 0x50f03c
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x14
ret 0x24