Function at 0x4014e0
Capabilities:
Check if file exists
Create directory

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x41b5f0
mov eax, dword fs:[0]
push eax
sub esp, 0x38
push ebx
push esi
push edi
mov eax, dword [0x422050]
xor eax, esp
push eax
lea eax, [esp + 0x48]
mov dword fs:[0], eax
lea eax, [esp + 0x2c]
push eax
call fcn.00405840
lea ecx, [esp + 0x1c]
push ecx
mov ecx, dword [ebp + 8]
xor esi, esi
mov dword [esp + 0x54], esi
call fcn.00407a30
lea edx, [esp + 0x2c]
push edx
push 0x5c
push eax
mov byte [esp + 0x5c], 1
call fcn.00402b10
mov byte [esp + 0x5c], 0
mov eax, dword [esp + 0x28]
add eax, 0xfffffff0
add esp, 0xc
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x401563
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov edx, dword [0x423ac4]
mov eax, dword [edx + 0xc]
mov ecx, 0x423ac4
call eax
lea edi, [eax + 0x10]
mov dword [esp + 0x14], edi
mov byte [esp + 0x50], 2
mov eax, dword [esp + 0x3c]
mov ecx, eax
sub ecx, dword [esp + 0x38]
mov dword [esp + 0x18], esi
sar ecx, 2
mov dword [esp + 0x28], ecx
cmp ecx, esi
ja 0x40164b
lea eax, [edi - 0x10]
mov byte [esp + 0x50], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4015bd
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [esp + 0x50], 0xffffffff
mov esi, dword [esp + 0x38]
xor ebx, ebx
cmp esi, ebx
je 0x401612
mov eax, dword [esp + 0x3c]
mov edi, eax
cmp esi, eax
je 0x401609
lea esp, [esp]
mov eax, dword [esi]
sub eax, 0x10
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4015fe
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
add esi, 4
cmp esi, edi
jne 0x4015e0
mov esi, dword [esp + 0x38]
push esi
call fcn.00409655
add esp, 4
mov ecx, dword [esp + 0x2c]
push ecx
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x40], ebx
mov dword [esp + 0x44], ebx
call fcn.00409655
add esp, 4
mov eax, 1
mov ecx, dword [esp + 0x48]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [esp + 0x3c]
mov esi, dword [esp + 0x18]
sub eax, dword [esp + 0x38]
sar eax, 2
cmp esi, eax
jb 0x40165b
call fcn.0040bea2
mov ecx, dword [esp + 0x38]
mov esi, dword [ecx + esi*4]
mov ecx, dword [esi - 0x10]
mov edx, dword [ecx]
mov eax, dword [edx + 0x10]
sub esi, 0x10
call eax
cmp dword [esi + 0xc], 0
lea ecx, [esi + 0xc]
jl 0x401689
cmp eax, dword [esi]
jne 0x401689
mov ebx, esi
mov edx, 1
lock xadd dword [ecx], edx
jmp 0x4016c4
mov ecx, dword [esi + 4]
mov edx, dword [eax]
mov edx, dword [edx]
push 2
push ecx
mov ecx, eax
call edx
mov ebx, eax
test ebx, ebx
je 0x4017f4
mov eax, dword [esi + 4]
mov dword [ebx + 4], eax
mov eax, dword [esi + 4]
lea ecx, [eax + eax + 2]
push ecx
add esi, 0x10
lea edx, [eax + eax + 2]
push esi
push edx
lea eax, [ebx + 0x10]
push eax
call fcn.004096c0
add esp, 0x10
add ebx, 0x10
mov dword [esp + 0x1c], ebx
lea ecx, [esp + 0x1c]
push ecx
lea edx, [esp + 0x28]
push edx
lea ebx, [esp + 0x1c]
mov byte [esp + 0x58], 3
call fcn.00405640
push eax
lea eax, [esp + 0x2c]
push eax
mov ebx, 0x41ea7c
mov byte [esp + 0x60], 4
call fcn.00405700
add esp, 0x10
mov byte [esp + 0x50], 5
mov ecx, dword [eax]
lea eax, [ecx - 0x10]
lea esi, [edi - 0x10]
cmp eax, esi
je 0x401752
cmp dword [esi + 0xc], 0
lea ebx, [esi + 0xc]
jl 0x401741
mov edx, dword [eax]
cmp edx, dword [esi]
jne 0x401741
call fcn.00407b40
mov edi, eax
or eax, 0xffffffff
lock xadd dword [ebx], eax
dec eax
test eax, eax
jg 0x401738
mov ecx, dword [esi]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push esi
call eax
add edi, 0x10
mov dword [esp + 0x14], edi
jmp 0x401752
mov ebx, dword [ecx - 0xc]
push ecx
lea eax, [esp + 0x18]
call fcn.00407c10
mov edi, dword [esp + 0x14]
mov byte [esp + 0x50], 4
mov eax, dword [esp + 0x20]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x401777
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x50], 3
mov eax, dword [esp + 0x24]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40179c
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x50], 2
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4017c1
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov esi, dword [esp + 0x18]
test esi, esi
je 0x4017e0
push edi
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x4017e0
push eax
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
je 0x4017f9
inc esi
mov dword [esp + 0x18], esi
cmp esi, dword [esp + 0x28]
jb 0x401643
jmp 0x40159c
call fcn.00406830
lea eax, [edi - 0x10]
mov byte [esp + 0x50], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40181a
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x38]
test eax, eax
je 0x401838
mov edi, dword [esp + 0x3c]
call fcn.004077f0
mov ecx, dword [esp + 0x38]
push ecx
call fcn.00409655
add esp, 4
mov edx, dword [esp + 0x2c]
xor eax, eax
push edx
mov dword [esp + 0x3c], eax
mov dword [esp + 0x40], eax
mov dword [esp + 0x44], eax
call fcn.00409655
add esp, 4
xor eax, eax
mov ecx, dword [esp + 0x48]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret