Function at 0x40a270
Capabilities:
Delete file

Disassembly:
sub esp, 0x148
push ebp
push edi
call fcn.0040a0f0
mov ebp, eax
mov eax, dword [ebp + 8]
mov ecx, dword [eax - 8]
test ecx, ecx
je 0x40a5c7
mov ecx, dword [ebp + 0x20]
mov eax, dword [ecx - 8]
test eax, eax
jne 0x40a2a5
mov edx, dword [ebp + 0x44]
mov eax, dword [edx - 8]
test eax, eax
je 0x40a5c7
mov eax, dword [ebp + 0x48]
mov ecx, dword [eax - 0xc]
test ecx, ecx
jl 0x40a2bf
mov dword [esp + 8], eax
add eax, 0xfffffff4
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedIncrement]
jmp 0x40a2d5
mov eax, dword [0x4881a0]
mov dword [esp + 8], eax
mov ecx, dword [ebp + 0x48]
push ecx
lea ecx, [esp + 0xc]
call fcn.00402c90
mov edx, dword [esp + 8]
push edx
call fcn.0040a5e0
add esp, 4
test eax, eax
jg 0x40a305
mov eax, dword [esp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
lea ecx, [esp + 8]
call fcn.00403680
pop edi
mov al, 1
pop ebp
add esp, 0x148
ret
mov eax, dword [0x4881a0]
xor ecx, ecx
mov dword [esp + 0x1d], ecx
mov dword [esp + 0xc], eax
mov dword [esp + 0x21], ecx
mov dword [esp + 0x10], eax
mov eax, dword [esp + 8]
mov dword [esp + 0x25], ecx
mov dword [esp + 0x29], ecx
lea edx, [esp + 0x1c]
push esi
mov word [esp + 0x31], cx
push edx
push eax
mov byte [esp + 0x28], 0
mov byte [esp + 0x3b], cl
call fcn.00425760
add esp, 8
test al, al
je 0x40a37c
xor esi, esi
xor ecx, ecx
lea edx, [esp + 0x10]
mov cl, byte [esp + esi + 0x20]
push ecx
push str._02X
push edx
call fcn.00402d60
mov eax, dword [esp + 0x1c]
add esp, 0xc
lea ecx, [esp + 0x14]
push eax
mov eax, dword [eax - 8]
push eax
call fcn.004037d0
inc esi
cmp esi, 0x14
jl 0x40a34b
lea ecx, [esp + 0x34]
call fcn.00428b10
mov ecx, 0x31
xor eax, eax
lea edi, [esp + 0x8d]
mov byte [esp + 0x8c], 0
rep stosd dword es:[edi], eax
mov ecx, dword [0x4881a0]
lea edx, [esp + 0x8c]
stosw word es:[edi], ax
stosb byte es:[edi], al
mov eax, dword [ebp + 0x48]
mov dword [esp + 0x18], ecx
push edx
push eax
lea ecx, [esp + 0x3c]
call fcn.00449d30
mov edi, dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
je 0x40a433
xor esi, esi
mov eax, dword [0x4881a0]
xor ecx, ecx
mov cl, byte [esp + esi + 0x8c]
lea edx, [esp + 0x1c]
push ecx
push str._02X
push edx
mov dword [esp + 0x28], eax
call fcn.00402d60
mov eax, dword [esp + 0x28]
add esp, 0xc
lea ecx, [esp + 0x18]
push eax
mov eax, dword [eax - 8]
push eax
call fcn.004037d0
mov eax, dword [esp + 0x1c]
mov edx, dword [0x4881a4]
lea ecx, [eax - 0xc]
cmp ecx, edx
je 0x40a42d
add eax, 0xfffffff4
push eax
call edi
test eax, eax
jg 0x40a42d
mov edx, dword [esp + 0x1c]
add edx, 0xfffffff4
push edx
call fcn.004472d3
add esp, 4
inc esi
cmp esi, 0x10
jl 0x40a3cb
mov ecx, dword [esp + 0x14]
mov eax, dword [ebp + 0x44]
push ecx
push eax
call fcn.0044c1ff
add esp, 8
test eax, eax
pop esi
je 0x40a512
mov edx, dword [esp + 0x14]
mov eax, dword [ebp + 0x94]
push edx
push eax
call fcn.0044c1ff
add esp, 8
test eax, eax
je 0x40a512
mov eax, dword [esp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov eax, dword [esp + 0x14]
mov edx, dword [0x4881a4]
lea ecx, [eax - 0xc]
cmp ecx, edx
je 0x40a49f
add eax, 0xfffffff4
push eax
call edi
test eax, eax
jg 0x40a49f
mov edx, dword [esp + 0x14]
add edx, 0xfffffff4
push edx
call fcn.004472d3
add esp, 4
lea ecx, [esp + 0x30]
call fcn.00449160
mov eax, dword [esp + 0x10]
mov edx, dword [0x4881a4]
lea ecx, [eax - 0xc]
cmp ecx, edx
je 0x40a4d3
add eax, 0xfffffff4
push eax
call edi
test eax, eax
jg 0x40a4d3
mov edx, dword [esp + 0x10]
add edx, 0xfffffff4
push edx
call fcn.004472d3
add esp, 4
mov eax, dword [esp + 0xc]
mov edx, dword [0x4881a4]
lea ecx, [eax - 0xc]
cmp ecx, edx
je 0x40a4fe
add eax, 0xfffffff4
push eax
call edi
test eax, eax
jg 0x40a4fe
mov edx, dword [esp + 0xc]
add edx, 0xfffffff4
push edx
call fcn.004472d3
add esp, 4
lea ecx, [esp + 8]
call fcn.00403680
pop edi
mov al, 1
pop ebp
add esp, 0x148
ret
mov eax, dword [esp + 0x14]
mov edx, dword [0x4881a4]
lea ecx, [eax - 0xc]
cmp ecx, edx
je 0x40a53d
add eax, 0xfffffff4
push eax
call edi
test eax, eax
jg 0x40a53d
mov edx, dword [esp + 0x14]
add edx, 0xfffffff4
push edx
call fcn.004472d3
add esp, 4
lea ecx, [esp + 0x30]
call fcn.00449160
mov eax, dword [esp + 0x10]
mov edx, dword [0x4881a4]
lea ecx, [eax - 0xc]
cmp ecx, edx
je 0x40a571
add eax, 0xfffffff4
push eax
call edi
test eax, eax
jg 0x40a571
mov edx, dword [esp + 0x10]
add edx, 0xfffffff4
push edx
call fcn.004472d3
add esp, 4
mov eax, dword [esp + 0xc]
mov edx, dword [0x4881a4]
lea ecx, [eax - 0xc]
cmp ecx, edx
je 0x40a59c
add eax, 0xfffffff4
push eax
call edi
test eax, eax
jg 0x40a59c
mov edx, dword [esp + 0xc]
add edx, 0xfffffff4
push edx
call fcn.004472d3
add esp, 4
mov eax, dword [esp + 8]
mov edx, dword [0x4881a4]
lea ecx, [eax - 0xc]
cmp ecx, edx
je 0x40a5c7
add eax, 0xfffffff4
push eax
call edi
test eax, eax
jg 0x40a5c7
mov edx, dword [esp + 8]
add edx, 0xfffffff4
push edx
call fcn.004472d3
add esp, 4
pop edi
xor al, al
pop ebp
add esp, 0x148
ret