Function at 0x40c4d0
Capabilities:
Check if file exists
Get file size
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x41bc90
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x24c
push ebx
push esi
mov edx, ecx
push edi
xor ebx, ebx
mov ecx, 0x81
xor eax, eax
lea edi, [ebp - 0x256]
mov word [ebp - 0x258], bx
mov dword [ebp - 0x10], esp
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov eax, dword [ebp + 0xc]
lea edi, [edx + 0xc]
push eax
push edi
lea ecx, [ebp - 0x258]
push str._s_s
push ecx
mov dword [ebp - 0x48], edx
call fcn.0041296e
add esp, 0x10
lea edx, [ebp - 0x258]
push edx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x40c555
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
push ebx
push 0x8000000
push 3
push ebx
push ebx
lea eax, [ebp - 0x258]
push 0x80000000
push eax
mov dword [ebp - 0x2c], ebx
mov dword [ebp - 0x14], ebx
mov dword [ebp - 4], ebx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
mov dword [ebp - 0x28], eax
jne 0x40c593
lea ecx, [ebp - 0x4c]
push 0x41f860
push ecx
mov dword [ebp - 0x4c], ebx
call fcn.00413206
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
cmp esi, 0xffffffff
je 0x40c732
cmp esi, ebx
je 0x40c732
mov edx, dword [ebp - 0x28]
push ebx
push esi
push ebx
push 2
push ebx
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileMappingW]
cmp eax, ebx
mov dword [ebp - 0x2c], eax
jne 0x40c5d6
lea eax, [ebp - 0x44]
push 0x41f860
push eax
mov dword [ebp - 0x44], ebx
call fcn.00413206
push ebx
push ebx
push ebx
push 4
push eax
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
cmp eax, ebx
mov dword [ebp - 0x14], eax
jne 0x40c5fa
lea ecx, [ebp - 0x40]
push 0x41f860
push ecx
mov dword [ebp - 0x40], ebx
call fcn.00413206
mov dl, byte [ebp + 0xf]
push ebx
lea ecx, [ebp - 0x3c]
mov byte [ebp - 0x3c], dl
shr esi, 1
call fcn.00409580
push 1
push esi
lea ecx, [ebp - 0x3c]
call fcn.00409450
cmp al, bl
je 0x40c635
mov eax, dword [ebp - 0x14]
mov ecx, dword [ebp - 0x38]
push esi
push eax
push ecx
call fcn.00401b80
mov edx, dword [ebp - 0x38]
mov dword [ebp - 0x34], esi
add esp, 0xc
mov word [edx + esi*2], bx
mov al, byte [ebp + 0xf]
push ebx
lea ecx, [ebp - 0x24]
mov byte [ebp - 4], 1
mov byte [ebp - 0x24], al
call fcn.00409580
push 0x426c34
call fcn.0041255c
add esp, 4
mov esi, eax
lea ecx, [ebp - 0x24]
push 1
push esi
call fcn.00409450
cmp al, bl
je 0x40c682
mov ecx, dword [ebp - 0x20]
push esi
push 0x426c34
push ecx
call fcn.00401b80
mov edx, dword [ebp - 0x20]
mov dword [ebp - 0x1c], esi
add esp, 0xc
mov word [edx + esi*2], bx
mov eax, dword [ebp - 0x48]
mov byte [ebp - 4], 2
mov ecx, dword [eax + 0x218]
cmp ecx, ebx
je 0x40c6a4
mov edx, dword [ecx]
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x3c]
push eax
call dword [edx + 0xc]
cmp al, bl
jne 0x40c6b8
mov ecx, dword [0x41d5a8]
lea edx, [ebp - 0x3c]
push ecx
push ebx
push edx
lea ecx, [ebp - 0x24]
call fcn.00409170
mov eax, dword [ebp - 0x20]
cmp eax, ebx
jne 0x40c6c4
mov eax, 0x41d59c
mov ecx, dword [ebp - 0x1c]
push edi
lea edx, [ecx + ecx]
push edx
push eax
mov eax, dword [ebp + 8]
push eax
call dword [sym.imp.MxUI.dll_HTMLayoutLoadHtmlEx]
mov ecx, dword [ebp - 0x20]
test eax, eax
setne byte [ebp + 0xf]
cmp ecx, ebx
je 0x40c702
mov al, byte [ecx - 1]
cmp al, bl
je 0x40c6f6
cmp al, 0xff
je 0x40c6f6
dec al
mov byte [ecx - 1], al
jmp 0x40c702
add ecx, 0xfffffffe
push ecx
call fcn.00411f90
add esp, 4
mov ecx, dword [ebp - 0x38]
mov dword [ebp - 0x20], ebx
cmp ecx, ebx
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 0x18], ebx
je 0x40c74f
mov al, byte [ecx - 1]
cmp al, bl
je 0x40c724
cmp al, 0xff
je 0x40c724
dec al
mov byte [ecx - 1], al
jmp 0x40c74f
add ecx, 0xfffffffe
push ecx
call fcn.00411f90
add esp, 4
jmp 0x40c74f
lea ecx, [ebp - 0x50]
push 0x41f860
push ecx
mov dword [ebp - 0x50], ebx
call fcn.00413206
mov byte [ebp + 0xf], 0
mov eax, 0x40c74d
ret
mov eax, dword [ebp - 0x14]
cmp eax, ebx
je 0x40c75d
push eax
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov eax, dword [ebp - 0x2c]
cmp eax, ebx
je 0x40c76b
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x28]
cmp eax, 0xffffffff
je 0x40c77a
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 0xc]
mov al, byte [ebp + 0xf]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret 8