Function at 0x440230
Capabilities:
Check if file exists
Delete directory
Delete file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5de57c
mov eax, dword fs:[0]
push eax
sub esp, 0x138
mov eax, dword [0x66c0e0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ecx + 0xbc]
lea edi, [ecx + 0xbc]
xor ebx, ebx
cmp dword [eax - 0xc], ebx
je 0x4404f5
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
je 0x4404f5
call fcn.004b5c24
xor ecx, ecx
cmp eax, ebx
setne cl
cmp ecx, ebx
jne 0x44029e
push 0x80004005
call fcn.004047e0
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [ebp - 0x13c], eax
push 0x5fd908
lea ecx, [ebp - 0x140]
push edi
push ecx
mov dword [ebp - 4], ebx
call fcn.0040c560
add esp, 0xc
push eax
lea ecx, [ebp - 0x13c]
mov byte [ebp - 4], 1
call fcn.00406510
mov eax, dword [ebp - 0x140]
add eax, 0xfffffff0
mov byte [ebp - 4], bl
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x4402fd
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov esi, dword [ebp - 0x13c]
cmp dword [esi - 4], 1
jle 0x44031e
mov ecx, dword [esi - 0xc]
push ecx
lea ecx, [ebp - 0x13c]
call fcn.00405c00
mov esi, dword [ebp - 0x13c]
lea edx, [ebp - 0x138]
push edx
push esi
call fcn.005bf14e
add esp, 8
mov dword [ebp - 0x140], eax
cmp eax, 0xffffffff
je 0x4404b6
push 0x5fc4e8
lea eax, [ebp - 0x144]
push edi
push eax
call fcn.0040c560
add esp, 0xc
push eax
lea ecx, [ebp - 0x13c]
mov byte [ebp - 4], 2
call fcn.00406510
mov eax, dword [ebp - 0x144]
add eax, 0xfffffff0
mov byte [ebp - 4], bl
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x440387
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea eax, [ebp - 0x114]
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
cmp cl, bl
jne 0x440390
sub eax, edx
push eax
lea ecx, [ebp - 0x114]
push ecx
lea ecx, [ebp - 0x13c]
call fcn.00408d70
mov esi, dword [ebp - 0x13c]
cmp dword [esi - 4], 1
jle 0x4403cd
mov edx, dword [esi - 0xc]
push edx
lea ecx, [ebp - 0x13c]
call fcn.00405c00
mov esi, dword [ebp - 0x13c]
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov ecx, dword [ebp - 0x140]
lea eax, [ebp - 0x138]
push eax
push ecx
call fcn.005bf275
add esp, 8
test eax, eax
jne 0x4404a7
push 0x5fc4e8
lea edx, [ebp - 0x144]
push edi
push edx
call fcn.0040c560
add esp, 0xc
push eax
lea ecx, [ebp - 0x13c]
mov byte [ebp - 4], 3
call fcn.00406510
mov eax, dword [ebp - 0x144]
add eax, 0xfffffff0
mov byte [ebp - 4], bl
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x44043c
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea eax, [ebp - 0x114]
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
cmp cl, bl
jne 0x440445
sub eax, edx
push eax
lea ecx, [ebp - 0x114]
push ecx
lea ecx, [ebp - 0x13c]
call fcn.00408d70
mov esi, dword [ebp - 0x13c]
cmp dword [esi - 4], 1
jle 0x440482
mov edx, dword [esi - 0xc]
push edx
lea ecx, [ebp - 0x13c]
call fcn.00405c00
mov esi, dword [ebp - 0x13c]
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov ecx, dword [ebp - 0x140]
lea eax, [ebp - 0x138]
push eax
push ecx
call fcn.005bf275
add esp, 8
test eax, eax
je 0x4403f2
mov edx, dword [ebp - 0x140]
push edx
call fcn.005bf0ac
add esp, 4
mov eax, dword [edi]
cmp dword [eax - 4], 1
jle 0x4404c9
mov eax, dword [eax - 0xc]
push eax
mov ecx, edi
call fcn.00405c00
mov edi, dword [edi]
push edi
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
lea eax, [esi - 0x10]
mov dword [ebp - 4], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4404f5
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.005bb30e
mov esp, ebp
pop ebp
ret