Function at 0x405c90
Capabilities:
Delete file
Move file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4215e7
mov eax, dword fs:[0]
push eax
sub esp, 0x47c
mov eax, dword [0x4360c0]
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 esi, ecx
mov dword [ebp - 0x488], esi
mov eax, dword [0x4397c8]
cmp dword [eax - 0xc], 0
jne 0x405cd6
call fcn.00404960
mov eax, 0x5c
mov word [ebp - 0x20], ax
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x18], 0
push 0
push 0x42861c
mov ecx, esi
mov dword [ebp - 4], 0
call fcn.00402320
push str.mergecell.dict
lea eax, [ebp - 0x47c]
push 0x4397c8
push eax
call fcn.00407400
add esp, 0xc
mov byte [ebp - 4], 1
push dword [ebp - 0x47c]
lea ecx, [ebp - 0x478]
call fcn.004028c0
or ebx, 0xffffffff
test eax, eax
je 0x405d95
lea eax, [ebp - 0x44c]
push eax
lea eax, [ebp - 0x484]
push 0x4397c8
push eax
call fcn.00407400
add esp, 0xc
push eax
lea ecx, [ebp - 0x47c]
mov byte [ebp - 4], 2
call fcn.00407120
mov byte [ebp - 4], 1
mov edx, dword [ebp - 0x484]
add edx, 0xfffffff0
mov ecx, ebx
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x405d85
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
push dword [ebp - 0x47c]
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
je 0x405da3
lea eax, [ebp - 0x47c]
push eax
mov ecx, esi
call fcn.00407120
push str.mergecell_.dict
lea eax, [ebp - 0x480]
push 0x4397c8
push eax
call fcn.00407400
add esp, 0xc
mov byte [ebp - 4], 3
mov ecx, dword [eax]
mov esi, dword [ebp - 0x47c]
lea edx, [ecx - 0x10]
add esi, 0xfffffff0
cmp edx, esi
je 0x405e23
cmp dword [esi + 0xc], 0
lea edi, [esi + 0xc]
jl 0x405e14
mov eax, dword [edx]
cmp eax, dword [esi]
jne 0x405e14
push edx
call fcn.00407780
add esp, 4
mov dword [ebp - 0x484], eax
mov ecx, ebx
lock xadd dword [edi], ecx
dec ecx
test ecx, ecx
jg 0x405e09
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, dword [ebp - 0x484]
add eax, 0x10
mov dword [ebp - 0x47c], eax
jmp 0x405e23
push dword [ecx - 0xc]
push ecx
lea ecx, [ebp - 0x47c]
call fcn.00402320
mov byte [ebp - 4], 1
mov edx, dword [ebp - 0x480]
add edx, 0xfffffff0
mov ecx, ebx
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x405e46
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
push dword [ebp - 0x47c]
lea ecx, [ebp - 0x478]
call fcn.004028c0
test eax, eax
je 0x405f46
nop
lea eax, [ebp - 0x44c]
push eax
lea eax, [ebp - 0x484]
push 0x4397c8
push eax
call fcn.00407400
add esp, 0xc
mov byte [ebp - 4], 4
mov ecx, dword [eax]
mov esi, dword [ebp - 0x47c]
lea edx, [ecx - 0x10]
add esi, 0xfffffff0
cmp edx, esi
je 0x405ee2
cmp dword [esi + 0xc], 0
lea edi, [esi + 0xc]
jl 0x405ed3
mov eax, dword [edx]
cmp eax, dword [esi]
jne 0x405ed3
push edx
call fcn.00407780
add esp, 4
mov dword [ebp - 0x480], eax
mov ecx, ebx
lock xadd dword [edi], ecx
dec ecx
test ecx, ecx
jg 0x405ec8
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, dword [ebp - 0x480]
add eax, 0x10
mov dword [ebp - 0x47c], eax
jmp 0x405ee2
push dword [ecx - 0xc]
push ecx
lea ecx, [ebp - 0x47c]
call fcn.00402320
mov byte [ebp - 4], 1
mov edx, dword [ebp - 0x484]
add edx, 0xfffffff0
mov ecx, ebx
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x405f05
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov esi, dword [ebp - 0x47c]
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x405f20
push 4
push eax
push esi
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
mov eax, dword [ebp - 0x1c]
test eax, eax
je 0x405f46
cmp dword [ebp - 0x18], 0
je 0x405f46
lea ecx, [ebp - 0x478]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
mov dword [ebp - 0x18], eax
test eax, eax
jne 0x405e60
mov ecx, dword [ebp - 0x488]
mov eax, dword [ecx]
cmp dword [eax - 0xc], 0
jne 0x406054
mov edi, 1
lea ecx, [ecx]
mov eax, dword [0x4397c8]
mov esi, dword [ebp - 0x47c]
lea edx, [eax - 0x10]
add esi, 0xfffffff0
cmp edx, esi
je 0x405fc7
cmp dword [esi + 0xc], 0
lea ebx, [esi + 0xc]
jl 0x405fb8
mov ecx, dword [edx]
cmp ecx, dword [esi]
jne 0x405fb8
push edx
call fcn.00407780
add esp, 4
mov dword [ebp - 0x480], eax
or ecx, 0xffffffff
lock xadd dword [ebx], ecx
dec ecx
test ecx, ecx
jg 0x405fad
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, dword [ebp - 0x480]
add eax, 0x10
mov dword [ebp - 0x47c], eax
jmp 0x405fc7
push dword [eax - 0xc]
lea ecx, [ebp - 0x47c]
push eax
call fcn.00402320
push edi
lea eax, [ebp - 0x47c]
push str.mergecell__d.dict
push eax
call fcn.00402580
add esp, 0xc
lea ecx, [ebp - 0x478]
push dword [ebp - 0x47c]
call fcn.004028c0
test eax, eax
je 0x405ff7
inc edi
jmp 0x405f60
mov ebx, dword [ebp - 0x488]
mov eax, dword [ebp - 0x47c]
mov esi, dword [ebx]
lea edx, [eax - 0x10]
sub esi, 0x10
cmp edx, esi
je 0x40606d
cmp dword [esi + 0xc], 0
lea edi, [esi + 0xc]
jl 0x40605c
mov ecx, dword [edx]
cmp ecx, dword [esi]
jne 0x40605c
push edx
call fcn.00407780
or ebx, 0xffffffff
add esp, 4
mov dword [ebp - 0x480], eax
mov ecx, ebx
lock xadd dword [edi], ecx
dec ecx
test ecx, ecx
jg 0x406049
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, dword [ebp - 0x480]
mov ecx, dword [ebp - 0x488]
add eax, 0x10
mov dword [ecx], eax
mov eax, dword [ebp - 0x47c]
jmp 0x406070
push dword [eax - 0xc]
mov ecx, ebx
push eax
call fcn.00402320
mov eax, dword [ebp - 0x47c]
or ebx, 0xffffffff
lea edx, [eax - 0x10]
mov byte [ebp - 4], 0
lea eax, [edx + 0xc]
lock xadd dword [eax], ebx
dec ebx
test ebx, ebx
jg 0x40608b
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0x18], 0
test eax, eax
je 0x4060a5
cmp eax, 0xffffffff
je 0x4060a5
push eax
call dword [sym.imp.KERNEL32.dll_FindClose]
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.00413156
mov esp, ebp
pop ebp
ret