Function at 0x1018947
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
mov edx, dword [ebp + 8]
movzx eax, byte [edx + 8]
dec eax
dec eax
push esi
je 0x1018932
sub eax, 3
je 0x1018843
dec eax
jne 0x1018a31
mov esi, dword [edx + 0x10]
cmp esi, reloc.msvcrt.dll___p__commode
je 0x1018a31
cmp dword [ebp + 0x14], 0
je 0x101882e
push 0
jmp 0x1018831
push dword [ebp + 0x10]
push dword [ebp + 0xc]
call fcn.0101831f
sub esi, eax
mov dword [edx + 0x10], esi
jmp 0x1018a31
mov esi, dword [edx + 0x1c]
test esi, esi
je 0x1018a31
cmp esi, reloc.msvcrt.dll___p__commode
je 0x1018a31
cmp dword [ebp + 0x14], 0
je 0x1018861
push 0
jmp 0x1018864
push dword [ebp + 0x10]
push dword [ebp + 0xc]
call fcn.0101831f
cmp esi, eax
jbe 0x1018a31
push dword [ebp + 0x10]
sub esi, eax
push dword [ebp + 0xc]
mov dword [edx + 0x1c], esi
call fcn.0101831f
mov ecx, eax
test ecx, ecx
mov dword [ebp + 0xc], ecx
fild dword [ebp + 0xc]
jge 0x1018896
fadd dword [0x1001310]
mov eax, dword [edx + 0x1c]
fild dword [edx + 0x1c]
test eax, eax
jge 0x10188a6
fadd dword [0x1001310]
fdivp st(1)
fadd dword [0x10027f4]
fld dword [0x1001310]
fcom dword [edx + 0x10]
fnstsw ax
test ah, 0x44
jnp 0x10188d6
fld dword [edx + 0x10]
fcomp dword [0x1024f8c]
fnstsw ax
test ah, 0x44
jnp 0x10188d6
fld dword [edx + 0x10]
fdiv st(2)
fstp dword [edx + 0x10]
fcom dword [edx + 0x18]
fnstsw ax
test ah, 0x44
jnp 0x10188f8
fld dword [edx + 0x18]
fcomp dword [0x1024f8c]
fnstsw ax
test ah, 0x44
jnp 0x10188f8
fld dword [edx + 0x18]
fdiv st(2)
fstp dword [edx + 0x18]
fcomp dword [edx + 0x14]
fnstsw ax
test ah, 0x44
jnp 0x101891a
fld dword [edx + 0x14]
fcomp dword [0x1024f8c]
fnstsw ax
test ah, 0x44
jnp 0x101891a
fld dword [edx + 0x14]
fdiv st(1)
fstp dword [edx + 0x14]
mov eax, dword [edx + 0x20]
fstp st(0)
cmp eax, reloc.msvcrt.dll___p__commode
je 0x1018a31
sub eax, ecx
mov dword [edx + 0x20], eax
jmp 0x1018a31
mov esi, dword [edx + 0x1c]
test esi, esi
je 0x1018a31
cmp esi, reloc.msvcrt.dll___p__commode
je 0x1018a31
cmp dword [ebp + 0x14], 0
je 0x1018950
push 0
jmp 0x1018953
push dword [ebp + 0x10]
push dword [ebp + 0xc]
call fcn.0101831f
mov ecx, eax
cmp esi, ecx
jbe 0x1018a31
mov eax, esi
sub eax, ecx
test ecx, ecx
mov dword [ebp + 0xc], ecx
fild dword [ebp + 0xc]
mov dword [edx + 0x1c], eax
jge 0x101897c
fadd dword [0x1001310]
test eax, eax
mov dword [ebp + 0xc], eax
fild dword [ebp + 0xc]
jge 0x101898c
fadd dword [0x1001310]
fdivp st(1)
fadd dword [0x10027f4]
fld dword [0x1001310]
fcom dword [edx + 0x10]
fnstsw ax
test ah, 0x44
jnp 0x10189bc
fld dword [edx + 0x10]
fcomp dword [0x1024f8c]
fnstsw ax
test ah, 0x44
jnp 0x10189bc
fld dword [edx + 0x10]
fdiv st(2)
fstp dword [edx + 0x10]
fcom dword [edx + 0x18]
fnstsw ax
test ah, 0x44
jnp 0x10189de
fld dword [edx + 0x18]
fcomp dword [0x1024f8c]
fnstsw ax
test ah, 0x44
jnp 0x10189de
fld dword [edx + 0x18]
fdiv st(2)
fstp dword [edx + 0x18]
fcom dword [edx + 0x14]
fnstsw ax
test ah, 0x44
jnp 0x1018a00
fld dword [edx + 0x14]
fcomp dword [0x1024f8c]
fnstsw ax
test ah, 0x44
jnp 0x1018a00
fld dword [edx + 0x14]
fdiv st(2)
fstp dword [edx + 0x14]
mov eax, dword [edx + 0x20]
cmp eax, reloc.msvcrt.dll___p__commode
je 0x1018a0d
sub eax, ecx
mov dword [edx + 0x20], eax
fcomp dword [edx + 0x28]
fnstsw ax
test ah, 0x44
jnp 0x1018a2f
fld dword [edx + 0x28]
fcomp dword [0x1024f8c]
fnstsw ax
test ah, 0x44
jnp 0x1018a2f
fld dword [edx + 0x28]
fdiv st(1)
fstp dword [edx + 0x28]
fstp st(0)
pop esi
pop ebp
ret 0x10