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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x16c
push ebx
push esi
push edi
sub esp, 0xc
mov esi, edx
push ecx
lea ecx, [esp + 0xd0]
call fcn.00402b70
sub esp, 0xc
lea ecx, [esp + 0x24]
push esi
call fcn.004035c0
sub esp, 8
lea eax, [esp + 0x18]
push eax
lea ecx, [esp + 0xcc]
call fcn.004026c0
mov ecx, dword [eax]
mov ecx, dword [ecx + 4]
add ecx, eax
mov eax, 0
test byte [ecx + 0xc], 6
cmovne ecx, eax
test ecx, ecx
je 0x401ccc
mov bl, byte [esp + 0x14]
lea ecx, [ecx]
lea ecx, [esp + 0xc0]
call fcn.00403e70
movzx ebx, bl
movzx ecx, al
cmp eax, 0xffffffff
cmovne ebx, ecx
xor esi, esi
mov byte [esp + 0x14], bl
cmp dword [esp + 0x10], esi
jle 0x401ca1
mov edi, dword [esp + 0x14]
jmp 0x401c90
push edi
lea ecx, [esp + 0x1c]
call fcn.004023e0
inc esi
cmp esi, dword [esp + 0x10]
jl 0x401c90
sub esp, 8
lea eax, [esp + 0x18]
push eax
lea ecx, [esp + 0xcc]
call fcn.004026c0
mov ecx, dword [eax]
mov ecx, dword [ecx + 4]
add ecx, eax
mov eax, 0
test byte [ecx + 0xc], 6
cmovne ecx, eax
test ecx, ecx
jne 0x401c60
cmp dword [esp + 0x120], 0
lea esi, [esp + 0xd0]
jne 0x401ce1
xor esi, esi
jmp 0x401d0a
lea ecx, [esp + 0xd0]
call fcn.004041c0
push dword [esp + 0x120]
xor ecx, ecx
test al, al
cmove esi, ecx
call fcn.004071f3
xor ecx, ecx
add esp, 4
test eax, eax
cmovne esi, ecx
lea eax, [esp + 0xd4]
mov dword [esp + 0xdc], eax
lea eax, [esp + 0xd8]
mov dword [esp + 0xe0], eax
lea eax, [esp + 0xe4]
mov dword [esp + 0xec], eax
lea eax, [esp + 0xe8]
mov dword [esp + 0xf0], eax
lea eax, [esp + 0xf4]
mov dword [esp + 0xfc], eax
lea eax, [esp + 0xf8]
mov dword [esp + 0x100], eax
mov eax, dword [0x429468]
mov byte [esp + 0x11c], 0
mov byte [esp + 0x115], 0
mov dword [esp + 0xd8], 0
mov dword [esp + 0xe8], 0
mov dword [esp + 0xf8], 0
mov dword [esp + 0xd4], 0
mov dword [esp + 0xe4], 0
mov dword [esp + 0xf4], 0
mov dword [esp + 0x120], 0
mov dword [esp + 0x118], eax
mov dword [esp + 0x110], 0
test esi, esi
jne 0x401dff
mov eax, dword [esp + 0xc0]
lea ecx, [esp + 0xc0]
mov eax, dword [eax + 4]
add ecx, eax
mov eax, dword [ecx + 0xc]
or eax, 2
cmp dword [ecx + 0x38], esi
jne 0x401df7
or eax, 4
push 0
push eax
call fcn.00401710
cmp dword [esp + 0x6c], 0
lea esi, [esp + 0x1c]
jne 0x401e0e
xor esi, esi
jmp 0x401e31
lea ecx, [esp + 0x1c]
call fcn.004041c0
push dword [esp + 0x6c]
xor ecx, ecx
test al, al
cmove esi, ecx
call fcn.004071f3
xor ecx, ecx
add esp, 4
test eax, eax
cmovne esi, ecx
lea eax, [esp + 0x20]
mov dword [esp + 0x28], eax
lea eax, [esp + 0x24]
mov dword [esp + 0x2c], eax
lea eax, [esp + 0x30]
mov dword [esp + 0x38], eax
lea eax, [esp + 0x34]
mov dword [esp + 0x3c], eax
lea eax, [esp + 0x40]
mov dword [esp + 0x48], eax
lea eax, [esp + 0x44]
mov dword [esp + 0x4c], eax
mov eax, dword [0x429468]
mov byte [esp + 0x68], 0
mov byte [esp + 0x61], 0
mov dword [esp + 0x24], 0
mov dword [esp + 0x34], 0
mov dword [esp + 0x44], 0
mov dword [esp + 0x20], 0
mov dword [esp + 0x30], 0
mov dword [esp + 0x40], 0
mov dword [esp + 0x6c], 0
mov dword [esp + 0x64], eax
mov dword [esp + 0x5c], 0
test esi, esi
jne 0x401edb
mov eax, dword [esp + 0x18]
lea ecx, [esp + 0x18]
mov eax, dword [eax + 4]
add ecx, eax
mov eax, dword [ecx + 0xc]
or eax, 2
cmp dword [ecx + 0x38], esi
jne 0x401ed3
or eax, 4
push 0
push eax
call fcn.00401710
mov eax, dword [esp + 0x18]
mov eax, dword [eax + 4]
mov dword [esp + eax + 0x18], vtable.std::basic_ofstream_char__struct_std::char_traits_char__.0
mov eax, dword [esp + 0x18]
mov ecx, dword [eax + 4]
lea eax, [ecx - 0x60]
mov dword [esp + ecx + 0x14], eax
cmp dword [esp + 0x6c], 0
mov dword [esp + 0x1c], vtable.std::basic_filebuf_char__struct_std::char_traits_char__.0
je 0x401f2b
mov edx, dword [esp + 0x28]
lea eax, [esp + 0x60]
cmp dword [edx], eax
jne 0x401f2b
mov eax, dword [esp + 0x54]
mov ecx, dword [esp + 0x58]
mov dword [edx], eax
mov eax, dword [esp + 0x38]
mov dword [eax], ecx
mov eax, dword [esp + 0x48]
sub ecx, ecx
mov dword [eax], ecx
cmp byte [esp + 0x68], 0
je 0x401f3b
lea ecx, [esp + 0x1c]
call fcn.00404070
mov esi, dword [esp + 0x50]
mov dword [esp + 0x1c], vtable.std::basic_streambuf_char__struct_std::char_traits_char__.0
test esi, esi
je 0x401f6b
mov ecx, dword [esi]
test ecx, ecx
je 0x401f62
mov eax, dword [ecx]
call dword [eax + 8]
test eax, eax
je 0x401f62
mov edx, dword [eax]
push 1
mov ecx, eax
call dword [edx]
push esi
call fcn.00406ee3
add esp, 4
mov eax, dword [esp + 0x18]
mov eax, dword [eax + 4]
mov dword [esp + eax + 0x18], vtable.std::basic_ostream_char__struct_std::char_traits_char__.0
mov eax, dword [esp + 0x18]
mov ecx, dword [eax + 4]
lea eax, [ecx - 8]
mov dword [esp + ecx + 0x14], eax
lea eax, [esp + 0x78]
push eax
mov dword [esp + 0x7c], vtable.std::ios_base.0
call fcn.0040557f
mov eax, dword [esp + 0xc4]
add esp, 4
mov eax, dword [eax + 4]
mov dword [esp + eax + 0xc0], vtable.std::basic_ifstream_char__struct_std::char_traits_char__.0
mov eax, dword [esp + 0xc0]
mov ecx, dword [eax + 4]
lea eax, [ecx - 0x70]
mov dword [esp + ecx + 0xbc], eax
cmp dword [esp + 0x120], 0
mov dword [esp + 0xd0], vtable.std::basic_filebuf_char__struct_std::char_traits_char__.0
je 0x402011
mov edx, dword [esp + 0xdc]
lea eax, [esp + 0x114]
cmp dword [edx], eax
jne 0x402011
mov eax, dword [esp + 0x108]
mov ecx, dword [esp + 0x10c]
mov dword [edx], eax
mov eax, dword [esp + 0xec]
mov dword [eax], ecx
mov eax, dword [esp + 0xfc]
sub ecx, ecx
mov dword [eax], ecx
cmp byte [esp + 0x11c], 0
je 0x402027
lea ecx, [esp + 0xd0]
call fcn.00404070
mov esi, dword [esp + 0x104]
mov dword [esp + 0xd0], vtable.std::basic_streambuf_char__struct_std::char_traits_char__.0
test esi, esi
je 0x40205d
mov ecx, dword [esi]
test ecx, ecx
je 0x402054
mov eax, dword [ecx]
call dword [eax + 8]
test eax, eax
je 0x402054
mov edx, dword [eax]
push 1
mov ecx, eax
call dword [edx]
push esi
call fcn.00406ee3
add esp, 4
mov eax, dword [esp + 0xc0]
mov eax, dword [eax + 4]
mov dword [esp + eax + 0xc0], vtable.std::basic_istream_char__struct_std::char_traits_char__.0
mov eax, dword [esp + 0xc0]
mov ecx, dword [eax + 4]
lea eax, [ecx - 0x18]
mov dword [esp + ecx + 0xbc], eax
lea eax, [esp + 0x130]
push eax
mov dword [esp + method.std::ios_base.virtual_0], vtable.std::ios_base.0
call fcn.0040557f
add esp, 4
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret