Function at 0x40c8f0
Capabilities:
Read .ini file

Disassembly:
push 0xffffffffffffffff
push 0x4107e5
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x184
push ebx
push ebp
xor ebx, ebx
push esi
push edi
mov dword [esp + 0x28], ecx
mov dword [esp + 0x14], ebx
mov dword [esp + 0x19c], ebx
mov dword [esp + 0x18], ebx
mov dword [esp + 0x10], ebx
mov ecx, dword [ecx + 8]
mov byte [esp + 0x19c], 2
cmp ecx, ebx
je 0x40c93e
call fcn.0040ba80
jmp 0x40c940
xor eax, eax
mov ecx, dword [esp + 0x1a8]
mov ebp, dword [sym.imp.MSVCRT.dll_sprintf]
push ecx
push eax
lea edx, [esp + 0x38]
push str._s_Dialog__d
push edx
call ebp
add esp, 0x10
lea ecx, [esp + 0x18]
call fcn.0040cf90
push 0xc
call sub.MFC42.DLL_operatornew
add esp, 4
mov dword [esp + 0x24], eax
cmp eax, ebx
mov byte [esp + 0x19c], 3
je 0x40c98f
lea ecx, [esp + 0x30]
push ecx
mov ecx, eax
call fcn.0040cfe0
jmp 0x40c991
xor eax, eax
mov edi, dword [esp + 0x1ac]
lea edx, [esp + 0x30]
push edi
push 0x415040
push edx
mov byte [esp + 0x1a8], 2
mov dword [esp + 0x24], eax
call ebp
add esp, 0xc
lea ecx, [esp + 0x14]
call fcn.0040cf90
push 0xc
call sub.MFC42.DLL_operatornew
add esp, 4
mov dword [esp + 0x24], eax
cmp eax, ebx
mov byte [esp + 0x19c], 4
je 0x40c9e5
lea ecx, [esp + 0x30]
push ecx
mov ecx, eax
call fcn.0040cfe0
jmp 0x40c9e7
xor eax, eax
mov edx, dword [esp + 0x1a4]
push edi
push edx
mov byte [esp + 0x1a4], 2
mov dword [esp + 0x1c], eax
call dword [sym.imp.USER32.dll_GetDlgItem]
push eax
call sub.MFC42.DLL_CWnd::FromHandle
mov esi, eax
cmp esi, ebx
mov dword [esp + 0x2c], esi
jne 0x40ca32
lea ecx, [esp + 0x10]
call fcn.0040cf90
lea ecx, [esp + 0x18]
call fcn.0040cf90
lea ecx, [esp + 0x14]
call fcn.0040cf90
jmp 0x40cddc
mov eax, dword [esp + 0x28]
mov ecx, dword [eax + 0xc]
test ecx, ecx
jne 0x40cbe9
mov ecx, dword [esi + 0x20]
push 0
push 0
push 0x146
push ecx
call dword [sym.imp.USER32.dll_SendMessageA]
test eax, eax
mov dword [esp + 0x20], eax
mov dword [esp + 0x1c], 0
jle 0x40cbe9
jmp 0x40ca77
mov ebp, dword [sym.imp.MSVCRT.dll_sprintf]
mov edi, dword [esp + 0x1ac]
mov edx, dword [esp + 0x1c]
lea eax, [esp + 0x30]
push edx
push edi
push str._d__d
push eax
call ebp
add esp, 0x10
lea ecx, [esp + 0x14]
call fcn.0040cf90
push 0xc
call sub.MFC42.DLL_operatornew
add esp, 4
mov dword [esp + 0x24], eax
test eax, eax
mov byte [esp + 0x19c], 5
je 0x40cabd
lea ecx, [esp + 0x30]
push ecx
mov ecx, eax
call fcn.0040cfe0
jmp 0x40cabf
xor eax, eax
mov edx, dword [esp + 0x28]
mov ecx, eax
mov byte [esp + 0x19c], 2
mov dword [esp + 0x14], ecx
mov eax, dword [edx + 4]
test eax, eax
je 0x40cae7
mov ecx, eax
call fcn.0040ba80
mov ecx, dword [esp + 0x14]
mov edi, eax
jmp 0x40cae9
xor edi, edi
test ecx, ecx
je 0x40caf6
call fcn.0040ba80
mov esi, eax
jmp 0x40caf8
xor esi, esi
mov ecx, dword [esp + 0x18]
test ecx, ecx
je 0x40cb07
call fcn.0040ba80
jmp 0x40cb09
xor eax, eax
push edi
lea ecx, [esp + 0x98]
push 0x100
push ecx
push 0x415ae8
push esi
push eax
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
test eax, eax
je 0x40cbbd
test ebx, ebx
jne 0x40cb45
mov edx, dword [esp + 0x2c]
push ebx
push ebx
push 0x14b
mov eax, dword [edx + 0x20]
push eax
call dword [sym.imp.USER32.dll_SendMessageA]
mov ecx, dword [esp + 0x10]
test ecx, ecx
je 0x40cb5a
call fcn.00404550
mov dword [esp + 0x10], 0
push 0xc
call sub.MFC42.DLL_operatornew
add esp, 4
mov dword [esp + 0x24], eax
test eax, eax
mov byte [esp + 0x19c], 6
je 0x40cb85
lea ecx, [esp + 0x94]
push ecx
mov ecx, eax
call fcn.0040cfe0
jmp 0x40cb87
xor eax, eax
test eax, eax
mov byte [esp + 0x19c], 2
mov dword [esp + 0x10], eax
je 0x40cba0
mov ecx, eax
call fcn.0040ba80
jmp 0x40cba2
xor eax, eax
mov edx, dword [esp + 0x2c]
push eax
push 0xffffffffffffffff
push 0x14a
mov eax, dword [edx + 0x20]
push eax
call dword [sym.imp.USER32.dll_SendMessageA]
mov ebx, 1
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x20]
inc eax
cmp eax, ecx
mov dword [esp + 0x1c], eax
jl 0x40ca6a
test ebx, ebx
je 0x40cbe5
mov ecx, dword [esp + 0x28]
mov eax, dword [ecx + 0xc]
test eax, eax
je 0x40cd64
mov esi, dword [esp + 0x2c]
mov edx, dword [esi + 0x20]
push 0
push 0
push 0x146
push edx
call dword [sym.imp.USER32.dll_SendMessageA]
mov ebp, eax
xor ebx, ebx
xor edi, edi
cmp ebp, ebx
mov dword [esp + 0x24], ebp
jle 0x40cd66
jmp 0x40cc16
mov esi, dword [esp + 0x2c]
xor ebx, ebx
mov ecx, dword [esi + 0x20]
lea eax, [esp + 0x30]
push eax
push edi
push 0x148
push ecx
call dword [sym.imp.USER32.dll_SendMessageA]
mov ecx, dword [esp + 0x10]
cmp ecx, ebx
je 0x40cc3c
call fcn.00404550
mov dword [esp + 0x10], ebx
push 0xc
call sub.MFC42.DLL_operatornew
add esp, 4
mov dword [esp + 0x20], eax
cmp eax, ebx
mov byte [esp + 0x19c], 7
je 0x40cc64
lea edx, [esp + 0x30]
mov ecx, eax
push edx
call fcn.0040cfe0
jmp 0x40cc66
xor eax, eax
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0x1ac]
push edi
push eax
lea ecx, [esp + 0x38]
push str._d__d
push ecx
mov byte [esp + 0x1ac], 2
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0x10
lea ecx, [esp + 0x14]
call fcn.0040cf90
push 0xc
call sub.MFC42.DLL_operatornew
add esp, 4
mov dword [esp + 0x20], eax
cmp eax, ebx
mov byte [esp + 0x19c], 8
je 0x40ccbf
lea edx, [esp + 0x30]
mov ecx, eax
push edx
call fcn.0040cfe0
jmp 0x40ccc1
xor eax, eax
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0x28]
mov byte [esp + 0x19c], 2
mov ecx, dword [eax + 4]
cmp ecx, ebx
je 0x40cce3
call fcn.0040ba80
mov dword [esp + 0x1c], eax
jmp 0x40cce7
mov dword [esp + 0x1c], ebx
mov ecx, dword [esp + 0x10]
cmp ecx, ebx
je 0x40ccfa
call fcn.0040ba80
mov dword [esp + 0x20], eax
jmp 0x40ccfe
mov dword [esp + 0x20], ebx
mov ecx, dword [esp + 0x14]
cmp ecx, ebx
je 0x40cd0d
call fcn.0040ba80
mov ebx, eax
mov eax, dword [esp + 0x18]
test eax, eax
je 0x40cd47
mov ecx, dword [eax + 4]
lea esi, [eax + 4]
test ecx, ecx
mov ebp, eax
jne 0x40cd3f
mov ecx, dword [eax]
push ecx
call fcn.0040edb3
test eax, eax
mov dword [esi], eax
jne 0x40cd3f
cmp dword [ebp], 0
je 0x40cd3f
push 0x8007000e
call fcn.0040ecf2
mov esi, dword [esi]
mov ebp, dword [esp + 0x24]
jmp 0x40cd49
xor esi, esi
mov edx, dword [esp + 0x1c]
mov eax, dword [esp + 0x20]
push edx
push eax
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringA]
inc edi
cmp edi, ebp
jl 0x40cc10
xor ebx, ebx
mov ecx, dword [esp + 0x10]
cmp ecx, ebx
je 0x40cd77
call fcn.00404550
mov dword [esp + 0x10], ebx
mov eax, dword [esp + 0x18]
mov edi, dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
cmp eax, ebx
mov byte [esp + 0x19c], 0
je 0x40cdb0
mov esi, eax
add eax, 8
push eax
call edi
test eax, eax
jne 0x40cda6
test esi, esi
je 0x40cda6
push 1
mov ecx, esi
call fcn.004045a0
mov dword [esp + 0x18], 0
xor ebx, ebx
mov eax, dword [esp + 0x14]
mov dword [esp + 0x19c], 0xffffffff
cmp eax, ebx
je 0x40cddc
mov esi, eax
add eax, 8
push eax
call edi
test eax, eax
jne 0x40cddc
test esi, esi
je 0x40cddc
push 1
mov ecx, esi
call fcn.004045a0
mov ecx, dword [esp + 0x194]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x190
ret 0xc