Function at 0x401490
Capabilities:
Get file size
Read .ini file
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4752d1
mov eax, dword fs:[0]
push eax
sub esp, 0x68
mov eax, dword [0x4ab028]
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 dword [ebp - 0x10], esp
mov esi, ecx
lea eax, [ebp + 8]
push eax
lea ecx, [ebp - 0x40]
mov dword [ebp - 4], 0
call dword [0x479d48]
mov edx, dword [ebp - 0x40]
lea ecx, [ebp - 0x38]
push ecx
push edx
call dword [sym.imp.MSVCR100.dll__wstat32]
add esp, 8
test eax, eax
lea ecx, [ebp - 0x40]
sete bl
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::CStringT_wchar_t_cla]
test bl, bl
je 0x40196d
mov byte [ebp - 4], 1
mov eax, dword [ebp + 8]
push eax
push 0xffffffffffffffff
push str.MAINID
push str.DICTIONARY_MAINID
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileIntW]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x40151e
or ebx, eax
lea ecx, [ebp - 0x54]
push ecx
lea edx, [ebp - 0x58]
add esi, 4
push edx
mov edi, ebx
call fcn.004029c0
test eax, eax
jne 0x401924
push 8
call dword [sym.imp.mfc100u.dll_new]
add esp, 4
mov dword [ebp - 0x54], eax
mov byte [ebp - 4], 2
test eax, eax
je 0x401559
push eax
call fcn.004027c0
mov dword [ebp - 0x40], eax
jmp 0x401560
mov dword [ebp - 0x40], 0
mov byte [ebp - 4], 1
mov eax, dword [ebp - 0x40]
push eax
mov eax, esi
call fcn.00402b00
mov ecx, dword [ebp + 8]
push 0
push 1
push 3
push 0
push 3
push SysReAllocString
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
mov dword [ebp - 0x58], esi
cmp esi, 0xffffffff
je 0x401924
push 0
push 0
push 0
push 2
push 0
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileMappingW]
mov dword [ebp - 0x60], eax
test eax, eax
je 0x401924
push 0
push 0
push 0
push 4
push eax
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov ebx, eax
mov dword [ebp - 0x68], ebx
test ebx, ebx
je 0x401924
push 0
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
test esi, esi
je 0x401924
push esi
call dword [sym.imp.mfc100u.dll_new__]
add esp, 4
push esi
mov edi, eax
push 0
push edi
mov dword [ebp - 0x54], edi
call sub.MSVCR100.dll_memset
push esi
push ebx
push edi
call sub.MSVCR100.dll_memcpy
add esp, 0x18
lea ecx, [ebp - 0x44]
call dword [0x479d7c]
push 0x47a1c0
lea ecx, [ebp - 0x4c]
mov byte [ebp - 4], 3
call dword [0x479d34]
lea ecx, [ebp - 0x48]
call dword [0x479d7c]
push edi
lea ecx, [ebp - 0x3c]
mov byte [ebp - 4], 5
call dword [0x479d34]
mov byte [ebp - 4], 6
mov edx, dword [ebp - 0x3c]
mov eax, dword [edx - 0xc]
add eax, 0xfffffffc
push eax
lea eax, [ebp - 0x50]
push eax
lea ecx, [ebp - 0x3c]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::Left]
push eax
lea ecx, [ebp - 0x3c]
mov byte [ebp - 4], 7
call dword [0x479d44]
lea ecx, [ebp - 0x50]
mov byte [ebp - 4], 6
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::CStringT_wchar_t_cla]
push 0x47a24c
push 0x47a1c4
lea ecx, [ebp - 0x3c]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::Replace_1]
mov edi, dword [sym.imp.mfc100u.dll_CMapStringToString::operator__]
push 0
push 0x5b
lea ecx, [ebp - 0x3c]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::Find]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x401861
push ebx
lea ecx, [ebp - 0x50]
push ecx
lea ecx, [ebp - 0x3c]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::Left]
push eax
lea ecx, [ebp - 0x48]
mov byte [ebp - 4], 8
call dword [0x479d44]
lea ecx, [ebp - 0x50]
mov byte [ebp - 4], 6
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::CStringT_wchar_t_cla]
lea ecx, [ebp - 0x48]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::Trim]
push eax
lea ecx, [ebp - 0x48]
call dword [0x479d44]
mov edx, dword [ebp - 0x44]
cmp dword [edx - 0xc], 0
je 0x40171e
push str.DICTIONARY_MAINID
lea ecx, [ebp - 0x44]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::CompareNoCase]
test eax, eax
je 0x40171e
push 0x47a1c0
lea ecx, [ebp - 0x4c]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::CompareNoCase]
test eax, eax
jne 0x40171e
mov eax, dword [ebp - 0x40]
mov edx, dword [ebp - 0x44]
mov ecx, dword [eax + 4]
mov esi, dword [ebp - 0x48]
push edx
call edi
push esi
mov ecx, eax
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::operator_2]
mov eax, dword [ebp - 0x3c]
mov eax, dword [eax - 0xc]
sub eax, ebx
dec eax
push eax
lea ecx, [ebp - 0x64]
push ecx
lea ecx, [ebp - 0x3c]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::Right]
push eax
lea ecx, [ebp - 0x3c]
mov byte [ebp - 4], 9
call dword [0x479d44]
lea ecx, [ebp - 0x64]
mov byte [ebp - 4], 6
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::CStringT_wchar_t_cla]
push 0
push 0x5d
lea ecx, [ebp - 0x3c]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::Find]
mov esi, eax
cmp esi, 0xffffffff
je 0x4018c6
push esi
lea edx, [ebp - 0x5c]
push edx
lea ecx, [ebp - 0x3c]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::Left]
push eax
lea ecx, [ebp - 0x44]
mov byte [ebp - 4], 0xa
call dword [0x479d44]
lea ecx, [ebp - 0x5c]
mov byte [ebp - 4], 6
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::CStringT_wchar_t_cla]
lea ecx, [ebp - 0x44]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::Trim]
push eax
lea ecx, [ebp - 0x44]
call dword [0x479d44]
mov eax, dword [ebp - 0x3c]
mov eax, dword [eax - 0xc]
sub eax, esi
dec eax
push eax
lea ecx, [ebp - 0x6c]
push ecx
lea ecx, [ebp - 0x3c]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::Right]
push eax
lea ecx, [ebp - 0x3c]
mov byte [ebp - 4], 0xb
call dword [0x479d44]
lea ecx, [ebp - 0x6c]
mov byte [ebp - 4], 6
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::CStringT_wchar_t_cla]
push 0
push 0x3d
lea ecx, [ebp - 0x3c]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::Find]
mov esi, eax
cmp esi, 0xffffffff
je 0x4018c6
push esi
lea edx, [ebp - 0x74]
push edx
lea ecx, [ebp - 0x3c]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::Left]
push eax
lea ecx, [ebp - 0x4c]
mov byte [ebp - 4], 0xc
call dword [0x479d44]
lea ecx, [ebp - 0x74]
mov byte [ebp - 4], 6
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::CStringT_wchar_t_cla]
lea ecx, [ebp - 0x4c]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::Trim]
push eax
lea ecx, [ebp - 0x4c]
call dword [0x479d44]
mov eax, dword [ebp - 0x3c]
mov eax, dword [eax - 0xc]
sub eax, esi
dec eax
push eax
lea ecx, [ebp - 0x70]
push ecx
lea ecx, [ebp - 0x3c]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::Right]
push eax
lea ecx, [ebp - 0x3c]
mov byte [ebp - 4], 0xd
call dword [0x479d44]
lea ecx, [ebp - 0x70]
mov byte [ebp - 4], 6
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::CStringT_wchar_t_cla]
jmp 0x401685
lea edx, [ebp - 0x3c]
push edx
lea ecx, [ebp - 0x48]
call dword [0x479d44]
lea ecx, [ebp - 0x48]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::Trim]
push eax
lea ecx, [ebp - 0x48]
call dword [0x479d44]
mov eax, dword [ebp - 0x44]
cmp dword [eax - 0xc], 0
je 0x4018c6
push str.DICTIONARY_MAINID
lea ecx, [ebp - 0x44]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::CompareNoCase]
test eax, eax
je 0x4018c6
push 0x47a1c0
lea ecx, [ebp - 0x4c]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::CompareNoCase]
test eax, eax
jne 0x4018c6
mov edx, dword [ebp - 0x44]
mov ecx, dword [ebp - 0x40]
mov ecx, dword [ecx + 4]
mov esi, dword [ebp - 0x48]
push edx
call edi
push esi
mov ecx, eax
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::operator_2]
mov eax, dword [ebp - 0x68]
push eax
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov ecx, dword [ebp - 0x60]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push ecx
call esi
mov edx, dword [ebp - 0x58]
push edx
call esi
mov eax, dword [ebp - 0x54]
test eax, eax
je 0x4018f3
push eax
call dword [sym.imp.mfc100u.dll_delete]
add esp, 4
mov ecx, dword [ebp - 0x40]
lea eax, [ebp + 8]
push eax
call dword [0x479d44]
lea ecx, [ebp - 0x3c]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::CStringT_wchar_t_cla]
lea ecx, [ebp - 0x48]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::CStringT_wchar_t_cla]
lea ecx, [ebp - 0x4c]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::CStringT_wchar_t_cla]
lea ecx, [ebp - 0x44]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::CStringT_wchar_t_cla]
lea ecx, [ebp + 8]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::CStringT_wchar_t_cla]
xor eax, eax
jmp 0x401979
lea ecx, [ebp + 8]
call dword [sym.imp.mfc100u.dll_ATL::CStringT_wchar_t_class_StrTraitMFC_DLL_wchar_t_class_ATL::ChTraitsCRT_wchar_t_____::CStringT_wchar_t_cla]
or eax, 0xffffffff
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.0046bf30
mov esp, ebp
pop ebp
ret 4