Function at 0x404c90
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x407fa0
push 0x40439e
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x118
push ebx
push esi
push edi
mov dword [ebp - 0x18], esp
mov esi, edx
mov dword [ebp - 0x128], esi
mov edi, ecx
mov dword [ebp - 0x124], edi
xor ebx, ebx
mov dword [ebp - 0x120], ebx
cmp dword [0x40ae20], ebx
jne 0x404ceb
call dword [sym.imp.rtapi_w32.dll_RtIsInRtss]
neg eax
sbb eax, eax
add eax, 2
mov dword [0x40ae20], eax
cmp dword [0x40a1d4], 0xffffffff
jne 0x404cff
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
mov dword [0x40a1d4], eax
mov dword [ebp - 4], ebx
mov dword [ebp - 4], 1
mov edx, esi
mov ecx, edi
call fcn.00404670
mov ebx, eax
mov dword [ebp - 0x120], ebx
test ebx, ebx
jne 0x404edf
mov eax, dword [esi + 0x1c]
cmp dword [eax], edi
je 0x404d40
mov ebx, 0x10000010
mov dword [ebp - 0x120], ebx
mov dword [ebp - 4], 0
jmp 0x404f0f
mov eax, dword [eax + 8]
test eax, eax
jne 0x404d5a
mov ebx, 0x10000018
mov dword [ebp - 0x120], ebx
mov dword [ebp - 4], eax
jmp 0x404f0f
cmp eax, 8
jne 0x404d76
mov ebx, 0x10000010
mov dword [ebp - 0x120], ebx
mov dword [ebp - 4], 0
jmp 0x404f0f
push edi
push str.GX6.IPC.ComRes.MT_u
lea eax, [ebp - 0x11c]
push eax
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0xc
lea ecx, [ebp - 0x11c]
push ecx
push 0
push 0x1f0003
call dword [sym.imp.rtapi_w32.dll_RtOpenSemaphoreA]
mov dword [esi + 0xc], eax
test eax, eax
jne 0x404ded
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
mov dword [ebp - 0x120], ebx
cmp dword [0x40ae20], 2
push ebx
jne 0x404de1
lea edx, [ebp - 0x11c]
push edx
push esi
push edi
push str.__MM____OpenComResResources_ulID:0x_08X_pHandleData:_p_:_RtOpenSemaphore__s__Error._0x_08X__n
call fcn.00403a90
add esp, 0x14
mov dword [ebp - 4], 0
jmp 0x404f0f
lea eax, [ebp - 0x11c]
push eax
jmp 0x404ed0
push edi
push str.GX6.IPC.ComRes.RS_u
lea ecx, [ebp - 0x11c]
push ecx
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0xc
lea edx, [ebp - 0x11c]
push edx
push 0
push 0x1f0003
call dword [sym.imp.rtapi_w32.dll_RtOpenSemaphoreA]
mov dword [esi + 0x14], eax
test eax, eax
jne 0x404e61
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
mov dword [ebp - 0x120], ebx
cmp dword [0x40ae20], 2
push ebx
jne 0x404e58
lea eax, [ebp - 0x11c]
push eax
push esi
push edi
push str.__MM____OpenComResResources_ulID:0x_08X_pHandleData:_p_:_RtOpenSemaphore__s__Error._0x_08X__n
call fcn.00403a90
add esp, 0x14
mov dword [ebp - 4], 0
jmp 0x404f0f
lea ecx, [ebp - 0x11c]
push ecx
jmp 0x404ed0
push edi
push str.GX6.IPC.ComRes.SS_u
lea edx, [ebp - 0x11c]
push edx
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0xc
lea eax, [ebp - 0x11c]
push eax
push 0
push 0x1f0003
call dword [sym.imp.rtapi_w32.dll_RtOpenSemaphoreA]
mov dword [esi + 0x18], eax
test eax, eax
jne 0x404edf
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
mov dword [ebp - 0x120], ebx
cmp dword [0x40ae20], 2
push ebx
jne 0x404ec9
lea ecx, [ebp - 0x11c]
push ecx
push esi
push edi
push str.__MM____OpenComResResources_ulID:0x_08X_pHandleData:_p_:_RtOpenSemaphore__s__Error._0x_08X__n
call fcn.00403a90
add esp, 0x14
mov dword [ebp - 4], 0
jmp 0x404f0f
lea edx, [ebp - 0x11c]
push edx
push esi
push edi
push str.__MC____OpenComResResources_ulID:0x_08X_pHandleData:_p_:_RtOpenSemaphore__s__Error._0x_08X__n
call fcn.00403a90
add esp, 0x14
mov dword [ebp - 4], 0
jmp 0x404f0f
mov dword [ebp - 4], 0xffffffff
call fcn.00404f48
test ebx, ebx
je 0x404fa7
cmp dword [0x40ae20], 2
push ebx
push esi
push edi
jne 0x404f9a
push str.__MM____OpenComResResources_ulID:0x_08X_pHandleData:_p_:_Error_0x_08X.__n
jmp 0x404f9f
push str.__MC____OpenComResResources_ulID:0x_08X_pHandleData:_p_:_Error_0x_08X.__n
call fcn.00403a90
add esp, 0x10
mov eax, ebx
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret