Function at 0x40d870
Capabilities:
Check os version
Resolve function by parsing pe exports

Disassembly:
push 0xffffffffffffffff
push 0x41ba0b
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x88
push esi
mov esi, ecx
mov eax, dword [esi + 0x6c]
push edi
xor edi, edi
cmp eax, edi
mov dword [esp + 0x30], esi
je 0x40db60
mov ecx, dword [esi + 0x70]
cmp ecx, edi
je 0x40d8bd
call sub.MFC71U.DLL_CListBox::DeleteItem
mov ecx, dword [esi + 0x70]
cmp ecx, edi
je 0x40d8ba
mov eax, dword [ecx]
push 1
call dword [eax + 4]
mov dword [esi + 0x70], edi
push 8
call sub.MFC71U.DLL_CWordArray::CWordArray
add esp, 4
cmp eax, edi
je 0x40d8d6
mov dword [eax + 4], edi
mov dword [eax], 0x41ecf0
jmp 0x40d8d8
xor eax, eax
mov edx, dword [esi + 0x20]
push ebx
push ebp
lea ecx, [esp + 0x6c]
push ecx
push edx
mov dword [esi + 0x70], eax
call dword [sym.imp.USER32.dll_GetClientRect]
mov ecx, dword [esp + 0x6c]
mov ebp, dword [esp + 0x74]
mov eax, dword [esp + 0x70]
mov ebx, dword [esp + 0x78]
sub ebp, ecx
sub ebx, eax
mov eax, dword [esi + 0x6c]
mov edx, dword [eax + 4]
lea ecx, [esp + 0x80]
push ecx
push 0x18
push edx
mov dword [esp + 0x40], ebx
call dword [sym.imp.GDI32.dll_GetObjectW]
xor eax, eax
mov dword [esp + 0x40], eax
mov dword [esp + 0x44], eax
mov dword [esp + 0x48], eax
mov dword [esp + 0x4c], eax
mov dword [esp + 0x50], eax
mov dword [esp + 0x54], eax
mov dword [esp + 0x58], eax
mov dword [esp + 0x5c], eax
mov dword [esp + 0x60], eax
lea ecx, [esp + 0x20]
mov dword [esp + 0x64], eax
mov dword [esp + 0x40], 0x28
mov dword [esp + 0x44], ebp
mov dword [esp + 0x48], ebx
mov word [esp + 0x4c], 1
mov word [esp + 0x4e], 0x18
call sub.MFC71U.DLL_CDBVariant::CDBVariant
mov eax, dword [esp + 0xa8]
cmp eax, edi
mov dword [esp + 0xa0], edi
jne 0x40d982
xor eax, eax
jmp 0x40d985
mov eax, dword [eax + 4]
push eax
call dword [sym.imp.GDI32.dll_CreateCompatibleDC]
push eax
lea ecx, [esp + 0x24]
call sub.MFC71U.DLL_CAsyncSocket::Attach
mov eax, dword [esp + 0x24]
push edi
push edi
lea ecx, [esp + 0x1c]
push ecx
push edi
lea edx, [esp + 0x50]
push edx
push eax
call dword [sym.imp.GDI32.dll_CreateDIBSection]
mov ecx, dword [esi + 0x70]
push eax
call sub.MFC71U.DLL_CDC::Attach
mov eax, dword [esi + 0x70]
cmp eax, edi
jne 0x40d9c2
xor eax, eax
jmp 0x40d9c5
mov eax, dword [eax + 4]
mov ecx, dword [esp + 0x24]
push eax
push ecx
call sub.MFC71U.DLL_COleControl::SelectFontObject
mov edx, dword [esi]
mov edi, eax
lea eax, [esp + 0x20]
push eax
mov ecx, esi
mov dword [esp + 0x40], edi
mov dword [esi + 0xb0], 0
call dword [edx + 0x13c]
mov eax, dword [esp + 0x14]
xor ecx, ecx
cmp eax, ecx
mov dword [esi + 0xb0], 1
je 0x40db11
lea eax, [ebp + ebp*2]
lea eax, [eax*8 + 0x1f]
cdq
and edx, 0x1f
add eax, edx
sar eax, 5
shl eax, 2
cmp ebx, ecx
mov dword [esp + 0x30], eax
mov dword [esp + 0x18], ecx
jle 0x40daed
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x10], ebx
mov edx, dword [esp + 0x14]
add ecx, edx
xor edi, edi
test ebp, ebp
jle 0x40dac5
mov eax, dword [esp + 0x10]
mov dword [esp + 0x7c], eax
mov eax, ebp
cmp edi, eax
mov edx, edi
jl 0x40da58
mov edx, eax
mov esi, dword [esp + 0x18]
cmp edx, esi
jl 0x40da62
mov edx, esi
mov esi, dword [esp + 0x10]
cmp edx, esi
jl 0x40da6c
mov edx, esi
cmp edx, 0xa
jl 0x40da76
mov edx, 0xa
imul edx, edx, 0x13
mov bl, dl
imul edx, edx, 0xff
not bl
movzx esi, bl
movzx ebx, byte [ecx]
imul ebx, esi
add ebx, edx
sar ebx, 8
mov byte [ecx], bl
movzx ebx, byte [ecx + 1]
inc ecx
imul ebx, esi
add ebx, edx
sar ebx, 8
mov byte [ecx], bl
movzx ebx, byte [ecx + 1]
inc ecx
imul ebx, esi
add ebx, edx
sar ebx, 8
inc ecx
mov byte [ecx - 1], bl
inc edi
dec eax
cmp edi, ebp
jl 0x40da50
mov esi, dword [esp + 0x38]
mov ebx, dword [esp + 0x34]
mov eax, dword [esp + 0x30]
mov edx, dword [esp + 0x18]
mov ecx, dword [esp + 0x1c]
mov edi, dword [esp + 0x10]
inc edx
add ecx, eax
dec edi
cmp edx, ebx
mov dword [esp + 0x18], edx
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x10], edi
jl 0x40da36
mov edi, dword [esp + 0x3c]
mov edx, dword [esp + 0x14]
mov eax, dword [esp + 0x24]
push 0
lea ecx, [esp + 0x44]
push ecx
push edx
push ebx
push 0
push 0
push 0
push ebx
push ebp
push 0
push 0
push eax
call dword [sym.imp.GDI32.dll_SetDIBitsToDevice]
test edi, edi
pop ebp
pop ebx
jne 0x40db1b
xor eax, eax
jmp 0x40db1e
mov eax, dword [edi + 4]
mov ecx, dword [esp + 0x1c]
push eax
push ecx
call sub.MFC71U.DLL_COleControl::SelectFontObject
lea ecx, [esp + 0x18]
call sub.MFC71U.DLL_CRichEditView::DeleteContents
xor ecx, ecx
xor eax, eax
mov dword [esi + 0xac], ecx
lea ecx, [esp + 0x18]
mov dword [esi + 0x94], 1
mov dword [esi + 0xa8], eax
mov dword [esp + 0x98], 0xffffffff
call fcn.00419c8c
mov ecx, dword [esp + 0x90]
pop edi
pop esi
mov dword fs:[0], ecx
add esp, 0x94
ret 4