Function at 0x504e10
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x53511d
mov eax, dword fs:[0]
push eax
sub esp, 0x970
mov eax, dword [0x5c6150]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, edx
mov edi, ecx
mov esi, dword [ebp + 8]
test edi, edi
jne 0x504e53
mov eax, 4
jmp 0x5051b7
mov eax, dword [edi + 0x20]
cmp eax, 3
jne 0x504e60
jmp 0x5051b7
cmp eax, 6
jne 0x504e6c
xor eax, eax
jmp 0x5051b7
cmp dword [ebx + 0x14], 8
mov eax, ebx
jb 0x504e76
mov eax, dword [ebx]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x504e8b
shr eax, 4
not al
and al, 1
jne 0x504e65
cmp dword [edi + 0x24], 1
je 0x504e49
xor eax, eax
mov dword [ebp - 0x34], 0
mov dword [ebp - 0x30], 7
mov word [ebp - 0x44], ax
mov dword [ebp - 4], eax
mov dword [ebp - 0x70], eax
mov dword [ebp - 0x6c], 7
mov word [ebp - 0x80], ax
mov byte [ebp - 4], 1
cmp dword [edi + 0x40], eax
je 0x505122
lea eax, [ebp - 0x80]
mov ecx, edi
push eax
lea edx, [ebp - 0x44]
call fcn.00505370
add esp, 4
test al, al
je 0x505122
test dword [edi + 0x40], 0x100
je 0x5050ad
lea ecx, [ebp - 0x68]
call fcn.005130f0
mov byte [ebp - 4], 3
lea eax, [ebp - 0x44]
cmp dword [ebp - 0x30], 8
push 1
cmovae eax, dword [ebp - 0x44]
push eax
call fcn.00512d60
test al, al
je 0x505031
push 0x5d10f0
lea ecx, [ebp - 0x68]
call fcn.00512730
push eax
call fcn.004d72ec
mov esi, eax
add esp, 8
mov dword [ebp - 0x974], esi
test esi, esi
jne 0x504f3a
lea esi, [eax + 4]
jmp 0x505099
lea eax, [ebp - 0x978]
mov dword [ebp - 0x978], 0
push eax
lea ecx, [ebp - 0x68]
mov byte [ebp - 0x96d], 0
call fcn.00512730
push eax
push esi
lea ecx, [ebp - 0x68]
call fcn.00512a20
test al, al
je 0x504f90
mov eax, dword [edi + 0x18]
lea ecx, [ebp - 0x68]
mov esi, dword [eax]
call fcn.00512730
mov ecx, dword [edi + 0x18]
push eax
push dword [ebp - 0x974]
mov eax, dword [esi + 0xc]
call eax
mov esi, dword [ebp - 0x974]
mov byte [ebp - 0x96d], al
push esi
call fcn.004d71b8
add esp, 4
lea ecx, [ebp - 0x68]
call fcn.00512c50
cmp byte [ebp - 0x96d], 0
jne 0x505013
mov eax, dword [edi + 0x24]
cmp eax, 3
je 0x504fbb
cmp eax, 4
jne 0x505094
cmp dword [0x5c80e8], 8
lea ecx, [ebp - 0x2c]
mov eax, 0x5c80d4
cmovae eax, dword [0x5c80d4]
push eax
call fcn.00514350
lea eax, [edi + 0x28]
mov byte [ebp - 4], 5
push eax
lea ecx, [ebp - 0x2c]
call fcn.00513fa0
lea ecx, [ebp - 0x2c]
call fcn.00513dd0
lea ecx, [ebp - 0x2c]
test al, al
je 0x50508f
mov edx, ebx
call fcn.00513a20
lea ecx, [ebp - 0x2c]
call fcn.004134c0
mov esi, 2
jmp 0x505099
lea ecx, [ebp - 0x68]
mov byte [ebp - 4], 0xb
call fcn.00512c50
lea ecx, [ebp - 0x64]
call fcn.004134c0
mov esi, 1
jmp 0x5051a5
mov eax, dword [edi + 0x24]
cmp eax, 3
je 0x50503e
cmp eax, 4
jne 0x505094
cmp dword [0x5c80e8], 8
lea ecx, [ebp - 0x2c]
mov eax, 0x5c80d4
cmovae eax, dword [0x5c80d4]
push eax
call fcn.00514350
lea eax, [edi + 0x28]
mov byte [ebp - 4], 8
push eax
lea ecx, [ebp - 0x2c]
call fcn.00513fa0
lea ecx, [ebp - 0x2c]
call fcn.00513dd0
lea ecx, [ebp - 0x2c]
test al, al
je 0x50508f
mov edx, ebx
call fcn.00513a20
lea ecx, [ebp - 0x2c]
call fcn.004134c0
mov esi, 2
jmp 0x505099
call fcn.004134c0
mov esi, 3
lea ecx, [ebp - 0x68]
mov byte [ebp - 4], 0xa
call fcn.00512c50
lea ecx, [ebp - 0x64]
jmp 0x5051a0
mov edx, str.UsrDict
mov ecx, edi
call fcn.00448240
test al, al
je 0x50510e
call fcn.00521240
push 0x69a
push str.t_dictManager::EnsureDict
push str.__S_L:_d__
call fcn.005212c0
add esp, 0xc
lea eax, [ebp - 0x44]
cmp dword [ebp - 0x30], 8
cmovae eax, dword [ebp - 0x44]
push eax
push str.begin_to_restore_usrdict:_s_r_n
call fcn.005212c0
add esp, 8
lea ecx, [ebp - 0x96c]
call fcn.005032c0
inc dword [ebp - 0x954]
lea ecx, [ebp - 0x96c]
call fcn.00500950
mov edx, ebx
lea ecx, [ebp - 0x44]
call fcn.00513a20
mov esi, 1
jmp 0x5051a5
cmp dword [0x5c80e8], 8
lea ecx, [ebp - 0x2c]
mov eax, 0x5c80d4
cmovae eax, dword [0x5c80d4]
push eax
call fcn.00514350
lea eax, [edi + 0x28]
mov byte [ebp - 4], 2
push eax
lea ecx, [ebp - 0x2c]
call fcn.00513fa0
mov eax, dword [edi + 0x24]
cmp eax, 3
je 0x50517b
cmp eax, 4
je 0x50517b
cmp eax, 2
jne 0x505198
lea ecx, [ebp - 0x2c]
call fcn.00513dd0
test al, al
je 0x505198
lea eax, [ebp - 0x2c]
mov ecx, esi
push eax
call fcn.00514000
xor esi, esi
jmp 0x50519d
lea ecx, [ebp - 0x2c]
call fcn.00513dd0
test al, al
je 0x505198
mov edx, ebx
lea ecx, [ebp - 0x2c]
call fcn.00513a20
mov esi, 2
jmp 0x50519d
mov esi, 3
lea ecx, [ebp - 0x2c]
call fcn.004134c0
lea ecx, [ebp - 0x80]
call fcn.004134c0
lea ecx, [ebp - 0x44]
call fcn.004134c0
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.004d6cfd
mov esp, ebp
pop ebp
ret