Function at 0x4fd970
Capabilities:
Get common file path
Print debug messages

Disassembly:
push ebp
mov ebp, esp
push 0xfffffffffffffffe
push 0x603548
push 0x55b400
mov eax, dword fs:[0]
push eax
sub esp, 0xe54
mov eax, dword [0x62d12c]
xor dword [ebp - 8], eax
xor eax, ebp
mov dword [ebp - 0x1c], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0x10]
mov dword fs:[0], eax
mov dword [ebp - 0x18], esp
mov eax, dword [ebp + 8]
mov dword [ebp - 0xe40], eax
mov edi, dword [ebp + 0xc]
mov dword [ebp - 0xe3c], edi
cmp byte [0x625296], 0
je 0x4fde1b
mov byte [0x625296], 0
push 0x208
push 0
lea ecx, [ebp - 0x224]
push ecx
call fcn.0055aed0
add esp, 0xc
push 0x206
lea edx, [ebp - 0x224]
push edx
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
mov ebx, dword [sym.imp.KERNEL32.dll_lstrcpyA]
test eax, eax
jne 0x4fda11
push 0x5c048c
lea eax, [ebp - 0x224]
push eax
call ebx
lea esi, [ebp - 0x224]
call fcn.004fc020
mov esi, eax
mov dword [ebp - 0xe44], esi
push esi
lea ecx, [ebp - 0x83c]
push ecx
call ebx
push 0x2e
lea eax, [ebp - 0x83c]
call fcn.004fb850
add esp, 4
test eax, eax
je 0x4fda45
mov byte [eax], 0
push str.ERRORLOG.TXT
push edi
push 0x5d8408
push 0xffffffffffffffff
push 0x208
lea edx, [ebp - 0x42c]
push edx
call fcn.00559bfd
add esp, 0x18
lea eax, [ebp - 0x42c]
push eax
push esi
call ebx
push 0
push 0x80000080
push 2
push 0
push 0
push 0x40000000
lea ecx, [ebp - 0x224]
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
mov dword [ebp - 0xe48], edi
cmp edi, 0xffffffff
jne 0x4fdb24
lea edx, [ebp - 0x634]
push edx
push 0x208
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
test eax, eax
je 0x4fdb0f
lea eax, [ebp - 0x634]
push eax
push 0x208
lea ecx, [ebp - 0x224]
push ecx
call fcn.00559feb
add esp, 0xc
lea esi, [ebp - 0x224]
call fcn.004fc020
mov dword [ebp - 0xe44], eax
lea edx, [ebp - 0x42c]
push edx
push eax
call ebx
push 0
push 0x80000080
push 2
push 0
push 0
push 0x40000000
mov eax, esi
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
mov dword [ebp - 0xe48], eax
cmp edi, 0xffffffff
jne 0x4fdb24
push str.Error_creating_exception_report_r_n
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
jmp 0x4fde1b
push 2
push 0
push 0
push edi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov eax, dword [ebp - 0xe40]
mov esi, dword [eax]
mov dword [ebp - 0xe30], esi
mov ebx, dword [eax + 4]
mov dword [ebp - 0xe38], ebx
push 0x208
push 0
lea ecx, [ebp - 0xa44]
push ecx
call fcn.0055aed0
add esp, 0xc
mov dword [ebp - 0xe34], 0x5c048c
push 0x1c
lea edx, [ebp - 0xe64]
push edx
mov eax, dword [ebx + 0xb8]
push eax
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x4fdbb6
push 0x206
lea ecx, [ebp - 0xa44]
push ecx
mov edx, dword [ebp - 0xe60]
push edx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
je 0x4fdbb6
lea esi, [ebp - 0xa44]
call fcn.004fc020
mov dword [ebp - 0xe34], eax
mov esi, dword [ebp - 0xe30]
mov eax, dword [esi]
mov dword [ebp - 0xe30], eax
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
mov ecx, dword [ebx + 0xb8]
push ecx
mov edx, dword [ebx + 0xbc]
push edx
mov eax, dword [ebp - 0xe34]
push eax
mov ecx, dword [ebp - 0xe30]
push ecx
call fcn.004fbe40
push eax
lea ecx, [ebp - 0x83c]
push ecx
push str._s_caused__s__0x_08x___r_nin_module__s_at__04x:_08x_CurrentThread:_08X._r_n_r_n
push edi
call fcn.004fb8c0
mov edx, dword [ebp - 0xe3c]
push edx
push str.Exception_handler_called_in__s._r_n
push edi
call fcn.004fb8c0
add esp, 0x30
call fcn.004fd000
cmp dword [esi], 0xc0000005
jne 0x4fdc5d
cmp dword [esi + 0x10], 2
jb 0x4fdc5d
mov eax, str.Read_from
cmp dword [esi + 0x14], 0
je 0x4fdc31
mov eax, str.Write_to
mov ecx, dword [esi + 0x18]
push ecx
push eax
push str._s_location__08x_caused_an_access_violation._r_n
lea edx, [ebp - 0xe2c]
push edx
call dword [sym.imp.USER32.dll_wsprintfA]
lea eax, [ebp - 0xe2c]
push eax
push 0x5be59c
push edi
call fcn.004fb8c0
add esp, 0x1c
mov esi, ebx
call fcn.004fc200
push str._r_nBytes_at_CS:EIP:_r_n
push edi
call fcn.004fb8c0
add esp, 8
mov ecx, dword [ebx + 0xb8]
mov dword [ebp - 0xe30], ecx
xor esi, esi
mov dword [ebp - 0xe34], esi
cmp esi, 0x10
jge 0x4fdce8
mov dword [ebp - 4], 0
mov edx, dword [ebp - 0xe30]
movzx eax, byte [esi + edx]
push eax
push 0x5d8308
push edi
call fcn.004fb8c0
add esp, 0xc
mov dword [ebp - 4], 0xfffffffe
inc esi
jmp 0x4fdc80
mov ecx, dword [ebx + 0xc4]
push ecx
push edi
call fcn.004fc040
push edi
call fcn.004fbda0
push str.ERRORLOG.TXT
push str._r_n__end_of__s___r_n
push edi
call fcn.004fb8c0
push edi
call fcn.004fb880
add esp, 0x1c
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
call fcn.004fd560
mov dword [ebp - 0xe38], eax
test eax, eax
je 0x4fde1b
push str.CRASH.DMP
mov edx, dword [ebp - 0xe3c]
push edx
push 0x5d8408
push 0xffffffffffffffff
push 0x208
lea eax, [ebp - 0x42c]
push eax
call fcn.00559bfd
add esp, 0x18
lea ecx, [ebp - 0x42c]
push ecx
mov edx, dword [ebp - 0xe44]
push edx
mov edi, dword [sym.imp.KERNEL32.dll_lstrcpyA]
call edi
push 0
push 0x80000080
push 2
push 0
push 0
push 0x40000000
lea eax, [ebp - 0x224]
push eax
mov ebx, dword [sym.imp.KERNEL32.dll_CreateFileA]
call ebx
mov esi, eax
cmp esi, 0xffffffff
jne 0x4fddf7
lea ecx, [ebp - 0x634]
push ecx
push 0x208
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
test eax, eax
je 0x4fddf2
lea edx, [ebp - 0x634]
push edx
push 0x208
lea eax, [ebp - 0x224]
push eax
call fcn.00559feb
add esp, 0xc
lea ecx, [ebp - 0x42c]
push ecx
lea esi, [ebp - 0x224]
call fcn.004fc020
push eax
call edi
push 0
push 0x80000080
push 2
push 0
push 0
push 0x40000000
mov edx, esi
push edx
call ebx
mov esi, eax
cmp esi, 0xffffffff
je 0x4fde0e
mov eax, dword [ebp - 0xe40]
push eax
push esi
call fcn.004fb940
add esp, 8
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 0xe38]
push ecx
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
xor eax, eax
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x1c]
xor ecx, ebp
call fcn.00558b78
mov esp, ebp
pop ebp
ret