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

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0xa8
mov esi, ecx
mov eax, dword [0x6f4e3c]
xor eax, ebp
mov dword [esp + 0xa0], eax
mov eax, str.DeleteFile.Recursive
mov ecx, str.DeleteFile.NonRecursive
test edx, edx
cmovne ecx, eax
mov dword [esp + 8], ecx
mov dword [esp + 4], edx
mov eax, edx
xor al, 1
movzx eax, al
mov dword [esp + 0xc], eax
lea edi, [esp + 0x68]
push 0x168
push str..._.._base_files_file_util_win.cc
push str.DeleteFileAndRecordMetrics
push edi
call fcn.00472ef0
add esp, 0x10
lea ecx, [esp + 0x10]
push 0
push edi
call fcn.0047d4a0
lea ebx, [esp + 0x58]
push 0x130
push str..._.._base_files_file_util_win.cc
push str.DoDeleteFile
push ebx
call fcn.00472ef0
add esp, 0x10
lea ecx, [esp + 0x68]
push 0
push ebx
call fcn.0047d4a0
movzx ecx, byte [esi + 0xb]
test cl, cl
mov eax, dword [esi + 4]
mov edx, ecx
cmovs edx, eax
mov dword [esp], 0
mov edi, 0
test edx, edx
je 0x481ee7
test cl, cl
jns 0x481d87
mov edi, 0xa1
cmp eax, 0x103
ja 0x481ee7
mov ecx, esi
push ebx
call fcn.0046f820
movzx eax, byte [esp + 0x63]
test al, al
jns 0x481da0
mov eax, dword [esp + 0x5c]
mov ebx, dword [esp + 0x58]
mov edi, 0xffffffff
test eax, eax
je 0x481dd1
add eax, eax
xor ecx, ecx
nop dword [eax]
movzx edx, word [ebx + ecx]
cmp dx, 0x3f
je 0x481dc9
cmp dx, 0x2a
je 0x481dc9
add ecx, 2
cmp eax, ecx
jne 0x481db0
jmp 0x481dd1
cmp eax, ecx
je 0x481dd1
sar ecx, 1
mov edi, ecx
lea ebx, [esp + 0x58]
mov ecx, ebx
call fcn.0046ee40
cmp edi, 0xffffffff
je 0x481e1e
mov ecx, esi
push ebx
call fcn.0046f820
lea edi, [esp + 0x4c]
mov ecx, esi
push edi
call fcn.0046f6e0
movzx eax, byte [esp + 4]
mov ecx, edi
mov edx, ebx
push eax
call fcn.00483800
add esp, 4
mov edi, eax
lea ecx, [esp + 0x4c]
call fcn.0046ee40
mov ecx, ebx
call fcn.0046ee40
jmp 0x481ee7
cmp byte [esi + 0xb], 0
mov eax, esi
jns 0x481e28
mov eax, dword [esi]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x481ed4
mov ebx, eax
test bl, 1
je 0x481e5a
mov eax, ebx
and eax, 0xfffffffe
cmp byte [esi + 0xb], 0
mov ecx, esi
jns 0x481e4e
mov ecx, dword [esi]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test eax, eax
je 0x481ed4
test bl, 0x10
jne 0x481e72
cmp byte [esi + 0xb], 0
mov eax, esi
jns 0x481e69
mov eax, dword [esi]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
jmp 0x481ecb
cmp byte [esp + 4], 0
je 0x481eba
mov dword [esp + 0x60], 0x1000000
mov dword [esp + 0x5c], 0
mov dword [esp + 0x58], 0x2a
lea edx, [esp + 0x58]
mov ecx, esi
push 1
call fcn.00483800
add esp, 4
mov edi, eax
cmp byte [esp + 0x63], 0
jns 0x481eb6
push dword [esp + 0x58]
call fcn.00517bd6
add esp, 4
test edi, edi
jne 0x481ee7
cmp byte [esi + 0xb], 0
mov eax, esi
jns 0x481ec4
mov eax, dword [esi]
push eax
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
mov edi, 0
test eax, eax
jne 0x481ee7
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, eax
and ecx, 0xfffffffe
xor edi, edi
cmp ecx, 2
cmovne edi, eax
mov eax, dword [esp + 0xc]
lea ebx, [eax + eax*2]
add ebx, 0x14
lea ecx, [esp + 0x68]
call fcn.0047d5c0
test edi, edi
je 0x481f56
cmp byte [esi + 0xb], 0
mov eax, esi
jns 0x481f08
mov eax, dword [esi]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x481f37
mov dword [esp], 7
test al, 0x10
je 0x481f56
push esi
call fcn.004713c0
add esp, 4
movzx eax, al
mov ecx, 6
sub ecx, eax
mov dword [esp], ecx
jmp 0x481f56
call dword [sym.imp.KERNEL32.dll_GetLastError]
lea ecx, [eax - 2]
mov dword [esp], 4
cmp ecx, 4
jae 0x481f56
mov eax, dword [eax*4 + 0x6524a0]
mov dword [esp], eax
mov dword [esp + 0x68], str.Windows.PostOperationState.
mov dword [esp + 0x6c], 0x1b
mov eax, dword [esp + 8]
mov dword [esp + 0x70], eax
mov dword [esp + 0x74], ebx
lea esi, [esp + 0x58]
lea eax, [esp + 0x68]
push eax
push 2
push esi
call fcn.004770e0
add esp, 0xc
push 8
push dword [esp + 4]
push esi
call fcn.00475ad0
add esp, 0xc
cmp byte [esp + 0x63], 0
jns 0x481fa8
push dword [esp + 0x58]
call fcn.00517bd6
add esp, 4
test edi, edi
je 0x481ff5
mov dword [esp + 0x68], str.Windows.FilesystemError.
mov dword [esp + 0x6c], 0x18
mov eax, dword [esp + 8]
mov dword [esp + 0x70], eax
mov dword [esp + 0x74], ebx
lea eax, [esp + 0x68]
push eax
push 2
push esi
call fcn.004770e0
add esp, 0xc
push edi
push esi
call fcn.00475b00
add esp, 8
cmp byte [esp + 0x63], 0
jns 0x481ff5
push dword [esp + 0x58]
call fcn.00517bd6
add esp, 4
test edi, edi
sete bl
lea ecx, [esp + 0x10]
call fcn.0047d5c0
mov ecx, dword [esp + 0xa0]
xor ecx, ebp
call fcn.00517c1a
mov eax, ebx
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret