Function at 0x40d200
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 0xcc
mov eax, dword [esp + 0xd4]
push ebx
mov ebx, dword [esp + 0xd4]
push ebp
push esi
xor esi, esi
mov ebp, ecx
cmp eax, esi
push edi
mov dword [esp + 0x18], ebp
je 0x40d274
call fcn.004110f0
cmp eax, esi
je 0x40d274
mov edi, ebx
mov ecx, eax
mov bl, byte [ecx]
mov dl, bl
cmp bl, byte [edi]
jne 0x40d255
test dl, dl
je 0x40d251
mov bl, byte [ecx + 1]
mov dl, bl
cmp bl, byte [edi + 1]
jne 0x40d255
add ecx, 2
add edi, 2
test dl, dl
jne 0x40d231
xor edi, edi
jmp 0x40d25a
sbb edi, edi
sbb edi, 0xffffffff
push eax
mov ecx, 0x4ba850
call fcn.00417540
cmp edi, esi
je 0x40dc7f
mov ebx, dword [esp + 0xe0]
mov ecx, ebp
call fcn.00410440
mov edi, dword [ebp + 0x2ac]
mov eax, dword [ebp]
mov ecx, dword [ebp + 4]
cmp edi, esi
mov dword [esp + 0x40], eax
mov dword [esp + 0x44], ecx
je 0x40d2b2
push 1
push edi
push esi
mov ecx, ebp
call fcn.00410160
push edi
push esi
mov ecx, ebp
call fcn.00410e50
push 1
push esi
push esi
mov ecx, ebp
call fcn.00410160
cmp dword [esp + 0xe4], esi
je 0x40dc06
mov eax, dword [ebp + 0xe4]
test ah, 2
je 0x40dc06
mov ecx, ebp
mov dword [esp + 0x50], esi
mov dword [esp + 0x54], esi
mov dword [esp + 0x58], esi
mov dword [esp + 0x68], esi
call fcn.0040f780
mov edx, dword [ebp + 0x20]
mov edi, eax
mov dword [esp + 0x48], edi
mov eax, dword [edx + 0x20]
mov edx, dword [ebp + 0x28]
mov ecx, dword [eax + 0x1e8]
push ecx
push edx
lea ecx, [esp + 0x74]
call fcn.0042d610
mov ecx, dword [ebp + 0x28]
xor eax, eax
cmp edi, 5
setg al
push eax
push 1
call fcn.00450f90
push eax
push edi
push ebx
lea ecx, [esp + 0x64]
call fcn.004584f0
lea ecx, [esp + 0x28]
call fcn.00457ad0
mov ecx, dword [ebp + 0x14]
lea ebx, [ebp + 0x48]
mov dword [esp + 0x68], ecx
push ebx
mov ecx, ebp
call fcn.00412b20
lea eax, [ebp + 0x130]
lea ecx, [esp + 0x14]
push eax
push ebx
push esi
mov dword [ebp + 0x138], esi
mov dword [esp + 0x20], esi
call fcn.0040d170
push ebx
lea ecx, [esp + 0x7c]
mov dword [esp + 0x28], esi
call fcn.0040dd50
mov edx, dword [ebx + 0x60]
mov eax, dword [ebp + 0x2c]
mov dword [esp + 0xd8], edx
mov dword [esp + 0x78], 0x4a3a48
mov ecx, dword [eax + 0x3b4]
lea edx, [esp + 0x28]
push ecx
push edx
lea ecx, [esp + 0x58]
call fcn.00457c70
test eax, eax
jne 0x40db3a
jmp 0x40d39f
xor esi, esi
cmp dword [esp + 0x2c], 3
jne 0x40d3c5
mov edx, dword [esp + 0x28]
or ecx, 0xffffffff
mov edi, edx
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push esi
push ecx
push edx
mov ecx, ebp
call fcn.0040ddc0
jmp case.default.0x40d40e
mov edi, dword [0x4a3a34]
xor esi, esi
cmp byte [edi], 0
je case.default.0x40d40e
mov eax, dword [esp + 0x28]
push eax
push edi
call fcn.004151f0
add esp, 8
test al, al
jne 0x40d3fc
mov cl, byte [edi]
inc esi
inc edi
test cl, cl
je 0x40d3f7
mov dl, byte [edi]
inc edi
test dl, dl
jne 0x40d3f0
cmp byte [edi], 0
jne 0x40d3d6
cmp byte [edi], 0
je case.default.0x40d40e
cmp esi, 0x12
ja case.default.0x40d40e
jmp dword [esi*4 + 0x40dc8c]
mov eax, dword [ebp + 0x2ac]
test eax, eax
je 0x40d449
dec eax
mov ecx, ebp
push eax
call fcn.0040c3c0
cmp ax, 0xa
je 0x40d449
cmp ax, 0xd
je 0x40d449
push 0
lea eax, [esp + 0x17]
push 1
push eax
mov ecx, ebp
mov byte [esp + 0x1f], 0xa
call fcn.0040ddc0
lea eax, [ebp + 0x130]
lea ecx, [esp + 0x14]
push eax
push ebx
push 0x4af5b4
call fcn.0040d170
mov dword [ebp + 0x150], 1
jmp case.default.0x40d40e
mov ecx, dword [esp + 0x28]
mov eax, dword [esp + 0x14]
inc ecx
test eax, eax
je case.default.0x40d40e
mov eax, dword [eax + 4]
test eax, eax
je case.default.0x40d40e
push eax
push ecx
call fcn.004151f0
add esp, 8
test al, al
je case.default.0x40d40e
push 0
lea edx, [esp + 0x17]
push 1
push edx
mov ecx, ebp
mov byte [esp + 0x1f], 0xa
call fcn.0040ddc0
mov esi, dword [esp + 0x14]
test esi, esi
je case.default.0x40d40e
lea edi, [esi + 8]
mov ecx, ebx
push edi
call fcn.00464d50
mov eax, dword [esp + 0x18]
lea ebp, [esi + 0x6c]
push ebp
lea ecx, [eax + 0x130]
call fcn.0040b690
mov ecx, dword [esp + 0x14]
mov edx, dword [ecx]
mov ecx, 0x4ba850
mov dword [esp + 0x14], edx
mov eax, dword [esi + 4]
push eax
call fcn.00417540
test esi, esi
je 0x40db14
mov ecx, ebp
call fcn.0040b590
mov ecx, edi
call fcn.0040dce0
jmp 0x40db0b
lea esi, [ebp + 0x130]
lea ecx, [esp + 0x14]
push esi
push ebx
push str.textformat
call fcn.0040d170
lea ecx, [esp + 0x1c]
push ecx
push str.leftmargin
lea ecx, [esp + 0x30]
call fcn.00457b70
test al, al
je 0x40d54b
mov eax, dword [esp + 0x1c]
lea edx, [eax + eax*4]
shl edx, 2
mov dword [ebp + 0x13c], edx
lea eax, [esp + 0x1c]
lea ecx, [esp + 0x28]
push eax
push str.rightmargin
call fcn.00457b70
test al, al
je 0x40d572
mov eax, dword [esp + 0x1c]
lea ecx, [eax + eax*4]
shl ecx, 2
mov dword [ebp + 0x140], ecx
lea edx, [esp + 0x1c]
lea ecx, [esp + 0x28]
push edx
push 0x4af588
call fcn.00457b70
test al, al
je 0x40d599
mov eax, dword [esp + 0x1c]
lea eax, [eax + eax*4]
shl eax, 2
mov dword [ebp + 0x144], eax
lea ecx, [esp + 0x1c]
push ecx
push str.blockindent
lea ecx, [esp + 0x30]
call fcn.00457b70
test al, al
je 0x40d5c0
mov eax, dword [esp + 0x1c]
lea edx, [eax + eax*4]
shl edx, 2
mov dword [ebp + 0x14c], edx
push str.tabstops
lea ecx, [esp + 0x2c]
call fcn.00457ba0
test eax, eax
je 0x40d5da
push eax
mov ecx, esi
call fcn.0040b4c0
lea eax, [esp + 0x1c]
lea ecx, [esp + 0x28]
push eax
push 0x4af568
call fcn.00457b70
test al, al
je case.default.0x40d40e
mov eax, dword [esp + 0x1c]
lea ecx, [eax + eax*4]
shl ecx, 2
mov dword [ebp + 0x148], ecx
jmp case.default.0x40d40e
mov edx, dword [esp + 0x28]
mov eax, dword [esp + 0x14]
test eax, eax
lea ecx, [edx + 1]
je case.default.0x40d40e
mov eax, dword [eax + 4]
test eax, eax
je case.default.0x40d40e
push eax
push ecx
call fcn.004151f0
add esp, 8
test al, al
je case.default.0x40d40e
mov esi, dword [esp + 0x14]
test esi, esi
je case.default.0x40d40e
lea edi, [esi + 8]
mov ecx, ebx
push edi
call fcn.00464d50
mov eax, dword [esp + 0x18]
lea ebp, [esi + 0x6c]
push ebp
lea ecx, [eax + 0x130]
call fcn.0040b690
mov ecx, dword [esp + 0x14]
mov edx, dword [ecx]
mov ecx, 0x4ba850
mov dword [esp + 0x14], edx
mov eax, dword [esi + 4]
push eax
call fcn.00417540
test esi, esi
je 0x40db14
mov ecx, ebp
call fcn.0040b590
mov ecx, edi
mov dword [edi], 0x4a3a48
call fcn.0040dd20
jmp 0x40db0b
lea eax, [ebp + 0x130]
lea ecx, [esp + 0x14]
push eax
push ebx
push 0x4af564
call fcn.0040d170
push 0x4af55c
lea ecx, [esp + 0x2c]
call fcn.00457ba0
test eax, eax
mov dword [esp + 0x24], eax
je 0x40d70c
mov esi, dword [0x4a3a38]
xor edi, edi
cmp byte [esi], 0
je 0x40d6ff
jmp 0x40d6dc
mov eax, dword [esp + 0x24]
push eax
push esi
call fcn.004151f0
add esp, 8
test al, al
jne 0x40d6ff
mov cl, byte [esi]
inc esi
test cl, cl
je 0x40d6f8
mov dl, byte [esi]
inc esi
test dl, dl
jne 0x40d6f1
mov al, byte [esi]
inc edi
test al, al
jne 0x40d6d8
cmp byte [esi], 0
jne 0x40d706
xor edi, edi
mov dword [ebp + 0x138], edi
mov dword [esp + 0x24], 1
jmp case.default.0x40d40e
mov eax, dword [esp + 0x24]
test eax, eax
je 0x40d7ca
lea eax, [esp + 0x78]
mov ecx, ebx
push eax
call fcn.00464d50
lea eax, [ebp + 0x130]
lea ecx, [esp + 0x14]
push eax
push ebx
push 0
call fcn.0040d170
push 0
lea ecx, [esp + 0x27]
push 1
push ecx
mov ecx, ebp
mov byte [esp + 0x2f], 0xa
call fcn.0040ddc0
mov esi, dword [esp + 0x14]
test esi, esi
je 0x40d7bc
lea edi, [esi + 8]
mov ecx, ebx
push edi
call fcn.00464d50
mov edx, dword [esp + 0x18]
lea ebp, [esi + 0x6c]
push ebp
lea ecx, [edx + 0x130]
call fcn.0040b690
mov eax, dword [esp + 0x14]
mov ecx, dword [eax]
mov dword [esp + 0x14], ecx
mov edx, dword [esi + 4]
push edx
mov ecx, 0x4ba850
call fcn.00417540
test esi, esi
je 0x40d7b8
mov ecx, ebp
call fcn.0040b590
mov ecx, edi
mov dword [edi], 0x4a3a48
call fcn.0040dd20
push esi
call fcn.00417900
add esp, 4
mov esi, dword [esp + 0x14]
mov ebp, dword [esp + 0x18]
mov dword [esp + 0x24], 0
jmp 0x40d7ce
mov esi, dword [esp + 0x14]
mov eax, dword [esp + 0x28]
inc eax
test esi, esi
je case.default.0x40d40e
mov esi, dword [esi + 4]
test esi, esi
je case.default.0x40d40e
push esi
push eax
call fcn.004151f0
add esp, 8
test al, al
je case.default.0x40d40e
mov esi, dword [esp + 0x14]
test esi, esi
je case.default.0x40d40e
lea edi, [esi + 8]
mov ecx, ebx
push edi
call fcn.00464d50
mov ecx, dword [esp + 0x18]
lea ebp, [esi + 0x6c]
push ebp
add ecx, 0x130
call fcn.0040b690
mov edx, dword [esp + 0x14]
mov eax, dword [edx]
mov dword [esp + 0x14], eax
mov ecx, dword [esi + 4]
push ecx
mov ecx, 0x4ba850
call fcn.00417540
test esi, esi
je 0x40db14
mov ecx, ebp
call fcn.0040b590
mov ecx, edi
mov dword [edi], 0x4a3a48
call fcn.0040dd20
jmp 0x40db0b
push 0
lea edx, [esp + 0x17]
push 1
push edx
mov ecx, ebp
mov byte [esp + 0x1f], 0xa
call fcn.0040ddc0
jmp case.default.0x40d40e
push 0
lea eax, [esp + 0x17]
push 1
push eax
mov ecx, ebp
mov byte [esp + 0x1f], 0xd
call fcn.0040ddc0
jmp case.default.0x40d40e
push 0
lea ecx, [esp + 0x17]
push 1
push ecx
mov ecx, ebp
mov byte [esp + 0x1f], 9
call fcn.0040ddc0
jmp case.default.0x40d40e
lea eax, [ebp + 0x130]
lea ecx, [esp + 0x14]
push eax
push ebx
push 0x4af298
call fcn.0040d170
push str.href
lea ecx, [esp + 0x2c]
call fcn.00457ba0
test eax, eax
je 0x40d8d9
push eax
mov ecx, ebx
call fcn.0040abc0
push 0x4af33c
lea ecx, [esp + 0x2c]
call fcn.00457ba0
test eax, eax
je case.default.0x40d40e
push eax
mov ecx, ebx
call fcn.0040abf0
jmp case.default.0x40d40e
lea eax, [ebp + 0x130]
lea ecx, [esp + 0x14]
push eax
push ebx
push 0x4af54c
call fcn.0040d170
push str.face
lea ecx, [esp + 0x2c]
call fcn.00457ba0
test eax, eax
je 0x40d930
mov ecx, dword [esp + 0x48]
mov edx, dword [ebx]
push ecx
push eax
mov ecx, ebx
call dword [edx]
push 0x4af53c
lea ecx, [esp + 0x2c]
call fcn.00457ba0
test eax, eax
je 0x40d987
cmp byte [eax], 0x23
jne 0x40d987
push 0
lea edx, [esp + 0x50]
push 0x10
inc eax
push edx
push eax
call fcn.00443090
add esp, 0x10
test eax, eax
je 0x40d987
mov eax, dword [esp + 0x4c]
mov byte [esp + 0x3b], 0xff
mov ecx, eax
mov edx, eax
sar ecx, 0x10
sar edx, 8
mov byte [esp + 0x38], cl
mov byte [esp + 0x39], dl
mov byte [esp + 0x3a], al
mov eax, dword [esp + 0x38]
mov dword [ebp + 0x94], eax
push 0x4af534
lea ecx, [esp + 0x2c]
call fcn.00457ba0
mov esi, eax
test esi, esi
je case.default.0x40d40e
push 0
lea ecx, [esp + 0x40]
push 0xa
push ecx
push esi
call fcn.00443090
add esp, 0x10
test eax, eax
je case.default.0x40d40e
mov eax, dword [esp + 0x3c]
lea eax, [eax + eax*4]
shl eax, 2
mov dword [esp + 0x3c], eax
mov cl, byte [esi]
cmp cl, 0x2b
je 0x40d9d3
cmp cl, 0x2d
jne 0x40d9e1
mov ecx, dword [ebp + 0x98]
test ecx, ecx
jge 0x40d9df
neg ecx
add eax, ecx
cmp eax, 0x9ec
jle 0x40d9ef
mov eax, 0x9ec
jmp 0x40d9f9
cmp eax, 0x14
jge 0x40d9f9
mov eax, 0x14
mov dword [esp + 0x3c], eax
mov ecx, ebx
neg eax
mov dword [ebx + 0x50], eax
call fcn.0040ab20
jmp case.default.0x40d40e
cmp esi, 6
jne 0x40da1a
mov esi, 1
jmp 0x40da27
sub esi, 7
neg esi
sbb esi, esi
and esi, 6
add esi, 2
mov edx, dword [esp + 0x28]
lea eax, [ebp + 0x130]
push eax
push ebx
push edx
lea ecx, [esp + 0x20]
call fcn.0040d170
mov eax, dword [ebp + 0x90]
and esi, 0xffff
or eax, esi
mov ecx, ebx
mov dword [ebx + 0x48], eax
call fcn.0040ab20
jmp case.default.0x40d40e
push ebx
lea ecx, [esp + 0x7c]
call fcn.00464d50
mov ecx, dword [esp + 0x28]
mov eax, dword [esp + 0x14]
inc ecx
test eax, eax
je case.default.0x40d40e
mov eax, dword [eax + 4]
test eax, eax
je case.default.0x40d40e
push eax
push ecx
call fcn.004151f0
add esp, 8
test al, al
je case.default.0x40d40e
mov esi, dword [esp + 0x14]
test esi, esi
je case.default.0x40d40e
lea edi, [esi + 8]
mov ecx, ebx
push edi
call fcn.00464d50
mov edx, dword [esp + 0x18]
lea ebp, [esi + 0x6c]
push ebp
lea ecx, [edx + 0x130]
call fcn.0040b690
mov eax, dword [esp + 0x14]
mov ecx, dword [eax]
mov dword [esp + 0x14], ecx
mov edx, dword [esi + 4]
push edx
mov ecx, 0x4ba850
call fcn.00417540
test esi, esi
je 0x40db14
mov ecx, ebp
call fcn.0040b590
mov eax, dword [edi + 0x3c]
mov ecx, 0x4ba850
push eax
mov dword [edi], 0x4a3a48
call fcn.00417540
mov ecx, dword [edi + 0x10]
push ecx
mov ecx, 0x4ba850
call fcn.00417540
mov edx, dword [edi + 4]
mov ecx, 0x4ba850
push edx
call fcn.00417540
push esi
call fcn.00417900
add esp, 4
mov ebp, dword [esp + 0x18]
mov eax, dword [ebp + 0x2c]
lea edx, [esp + 0x28]
mov ecx, dword [eax + 0x3b4]
push ecx
push edx
lea ecx, [esp + 0x58]
call fcn.00457c70
test eax, eax
je 0x40d39d
xor esi, esi
mov eax, dword [esp + 0xb4]
mov ecx, 0x4ba850
push eax
mov dword [esp + 0x7c], 0x4a3a48
call fcn.00417540
mov ecx, dword [esp + 0x88]
push ecx
mov ecx, 0x4ba850
call fcn.00417540
mov edx, dword [esp + 0x7c]
mov ecx, 0x4ba850
push edx
call fcn.00417540
mov eax, dword [esp + 0x14]
cmp eax, esi
je 0x40dbe1
mov esi, eax
mov eax, dword [eax]
mov dword [esp + 0x14], eax
mov ecx, dword [esi + 4]
push ecx
mov ecx, 0x4ba850
call fcn.00417540
test esi, esi
je 0x40dbd9
lea ecx, [esi + 0x6c]
call fcn.0040b590
mov edx, dword [esi + 0x44]
mov ecx, 0x4ba850
push edx
mov dword [esi + 8], 0x4a3a48
call fcn.00417540
mov eax, dword [esi + 0x18]
mov ecx, 0x4ba850
push eax
call fcn.00417540
mov ecx, dword [esi + 0xc]
push ecx
mov ecx, 0x4ba850
call fcn.00417540
push esi
call fcn.00417900
add esp, 4
mov eax, dword [esp + 0x14]
test eax, eax
jne 0x40db7d
lea ecx, [esp + 0x28]
call fcn.00457ae0
lea ecx, [esp + 0x6c]
call fcn.0042d6d0
mov edx, dword [esp + 0x50]
mov ecx, 0x4ba850
push edx
call fcn.00417540
xor esi, esi
jmp 0x40dc4b
push ebx
call fcn.00415360
mov ebx, eax
add esp, 4
cmp ebx, esi
je 0x40dc4b
cmp byte [ebx], 0
je 0x40dc2a
cmp byte [eax], 0xd
jne 0x40dc22
mov byte [eax], 0xa
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x40dc1a
mov edi, ebx
or ecx, 0xffffffff
xor eax, eax
push esi
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push ebx
mov ecx, ebp
call fcn.0040ddc0
push ebx
mov ecx, 0x4ba850
call fcn.00417540
mov eax, dword [esp + 0x40]
xor ecx, ecx
cmp eax, esi
setl cl
dec ecx
and ecx, eax
mov eax, dword [ebp + 0x2ac]
cmp eax, ecx
jge 0x40dc65
mov ecx, eax
mov dword [ebp], ecx
mov ecx, dword [esp + 0x44]
xor edx, edx
cmp ecx, esi
setl dl
dec edx
and ecx, edx
cmp eax, ecx
jl 0x40dc7c
mov eax, ecx
mov dword [ebp + 4], eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xcc
ret 8