Function at 0x581500
Capabilities:
Check if file exists
Delete file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5a280b
mov eax, dword fs:[0]
push eax
sub esp, 0x688
mov eax, dword [0x606040]
xor eax, ebp
mov dword [ebp - 0x18], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov ebx, ecx
mov eax, dword [ebp + 8]
mov dword [ebp - 0x654], eax
lea eax, [ebx + 0x4bc0]
mov dword [ebp - 4], 0
mov esi, dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
push eax
mov dword [ebp - 0x634], ebx
mov dword [ebp - 0x62c], 0
call esi
cmp dword [ebx + 0x4be8], 1
jae 0x581586
push 0x5fd754
lea eax, [ebp - 0x658]
mov dword [ebp - 0x658], 0xa0a
push eax
call fcn.00539115
mov eax, dword [ebx + 0x4bb8]
lea ecx, [ebx + 0x4bb8]
call dword [eax + 0x14]
jmp 0x5815a0
cmp dword [ebx + 0x4be8], 0
je 0x581ccc
lea eax, [ebx + 0x4bc0]
push eax
call esi
lea eax, [ebp - 0x694]
lea esi, [ebx + 0x4bd8]
push eax
mov ecx, esi
call fcn.00408950
mov ecx, dword [eax]
test ecx, ecx
jne 0x5815d4
xor edi, edi
jmp 0x5815d6
mov edi, dword [ecx]
mov edx, dword [eax + 8]
mov eax, edx
mov ecx, dword [edi + 8]
and edx, 3
shr eax, 2
dec ecx
and ecx, eax
mov eax, dword [edi + 4]
mov eax, dword [eax + ecx*4]
mov edi, dword [eax + edx*4]
sub edi, 0x10
mov ecx, dword [edi]
mov eax, dword [ecx]
call dword [eax + 0x10]
cmp dword [edi + 0xc], 0
lea ecx, [edi + 0xc]
mov edx, eax
jl 0x581614
cmp edx, dword [edi]
jne 0x581614
mov eax, 1
lock xadd dword [ecx], eax
jmp 0x58165f
mov eax, dword [edx]
mov ecx, edx
push 2
push dword [edi + 4]
call dword [eax]
mov edx, eax
mov dword [ebp - 0x610], edx
test edx, edx
jne 0x581630
call fcn.00402560
mov eax, dword [edi + 4]
mov dword [edx + 4], eax
mov ecx, dword [edi + 4]
lea eax, [ecx*2 + 2]
push eax
lea eax, [edi + 0x10]
push eax
lea eax, [ecx*2 + 2]
push eax
lea eax, [edx + 0x10]
push eax
call fcn.00535d59
mov edi, dword [ebp - 0x610]
add esp, 0x10
add edi, 0x10
mov dword [ebp - 0x688], edi
mov byte [ebp - 4], 1
mov edx, dword [esi + 0xc]
mov eax, edx
mov ecx, dword [esi + 8]
and edx, 3
shr eax, 2
dec ecx
and ecx, eax
mov eax, dword [esi + 4]
mov eax, dword [eax + ecx*4]
or ecx, 0xffffffff
mov edx, dword [eax + edx*4]
sub edx, 0x10
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x5816a0
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
dec dword [esi + 0x10]
jne 0x5816ae
mov dword [esi + 0xc], 0
jmp 0x5816b1
inc dword [esi + 0xc]
mov eax, dword [ebx + 0x4bb8]
lea ecx, [ebx + 0x4bb8]
call dword [eax + 0x14]
xor esi, esi
mov dword [ebp - 0x624], 0
mov dword [ebp - 0x610], esi
mov dword [ebp - 0x620], esi
mov dword [ebp - 0x61c], esi
mov byte [ebp - 4], 2
cmp dword [edi - 0xc], esi
je 0x581832
push edi
lea eax, [ebp - 0x42c]
push 0x104
push eax
call fcn.005363c5
add esp, 0xc
mov dword [ebp - 0x618], esi
lea eax, [ebp - 0x42c]
push str.r_ccsUTF_8
push eax
lea eax, [ebp - 0x618]
push eax
call fcn.00536c9e
add esp, 0xc
cmp dword [ebp - 0x618], esi
je 0x58185d
mov dword [ebp - 0x614], esi
push dword [ebp - 0x618]
lea eax, [ebp - 0x224]
push 0x104
push eax
call fcn.00536f1d
add esp, 0xc
test eax, eax
je 0x58181a
lea eax, [ebp - 0x614]
push eax
lea eax, [ebp - 0x224]
push 0x5de32c
push eax
call fcn.00536fd9
add esp, 0xc
lea eax, [ebp - 0x224]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x5817ac
push eax
mov edx, 0x104d01
mov ecx, ebx
call fcn.00574b30
add esp, 4
mov dword [ebp - 0x644], 0xa2c
lea eax, [ebp - 0x644]
push 0x5fd754
push eax
call fcn.00539115
lea eax, [ebp - 0x224]
push eax
lea ecx, [ebp - 0x638]
call fcn.00402cd0
lea eax, [ebp - 0x638]
mov byte [ebp - 4], 3
push eax
lea ecx, [ebp - 0x624]
call fcn.004084c0
mov byte [ebp - 4], 2
or ecx, 0xffffffff
mov edx, dword [ebp - 0x638]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jle 0x581801
mov esi, dword [ebp - 0x620]
mov dword [ebp - 0x610], esi
jmp 0x581733
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov esi, dword [ebp - 0x620]
mov dword [ebp - 0x610], esi
jmp 0x581733
push dword [ebp - 0x618]
call fcn.0053711a
add esp, 4
mov dword [ebp - 0x618], 0
mov eax, esi
sub eax, dword [ebp - 0x624]
sar eax, 2
cmp eax, 1
jae 0x581889
push 0x5fd754
lea eax, [ebp - 0x660]
mov dword [ebp - 0x660], 0xa3e
push eax
call fcn.00539115
push 0
mov edx, 0x104d02
mov ecx, ebx
call fcn.00574b30
add esp, 4
mov dword [ebp - 0x640], 0xa38
lea eax, [ebp - 0x640]
push 0x5fd754
push eax
call fcn.00539115
cmp dword [ebx + 0x4b2c], 0xa
jl 0x5818be
push 0
mov edx, 0x104901
mov ecx, ebx
call fcn.00574b30
add esp, 4
mov dword [ebp - 0x65c], 0xa45
lea eax, [ebp - 0x65c]
push 0x5fd754
push eax
call fcn.00539115
mov ecx, 0x5dbf80
call fcn.0042bb70
mov dword [ebp - 0x614], eax
mov dword [ebp - 0x62c], eax
test eax, eax
je 0x581c56
inc dword [ebx + 0x4bec]
mov ecx, eax
push dword [ebx + 0x4bec]
call fcn.0056d310
call fcn.0041a343
mov ecx, eax
test ecx, ecx
je 0x581903
mov eax, dword [ecx]
call dword [eax + 0x74]
mov edx, eax
jmp 0x581905
xor edx, edx
mov ecx, dword [ebp - 0x614]
lea esi, [ebp - 0x674]
xor eax, eax
push esi
mov dword [ebp - 0x674], eax
push edx
mov dword [ebp - 0x670], eax
mov dword [ebp - 0x66c], eax
mov dword [ebp - 0x668], eax
mov dword [ebp - 0x664], eax
mov eax, dword [ecx]
push 0x40cf0000
push 0x82
mov dword [ebp - str.CPDFEditorView], 0x5deaa0
call dword [eax + 0x164]
mov ecx, dword [ebp - 0x614]
mov esi, dword [ebp - 0x624]
push 1
push 0
call fcn.00414644
mov ecx, dword [ebp - 0x614]
mov edx, dword [ebx + 0x4b30]
push edx
mov dword [ebp - 0x63c], edx
mov eax, dword [ecx + 0x4f0]
push dword [eax]
call fcn.0056ce30
test eax, eax
je 0x581998
mov ecx, dword [ebp - 0x614]
push 1
mov eax, dword [ecx]
call dword [eax + 0x174]
mov eax, dword [ebp - 0x614]
mov ecx, dword [ebp - 0x63c]
mov eax, dword [eax + 0x4f0]
mov dword [ebp - 0x628], eax
mov dword [eax], ecx
mov ecx, eax
call fcn.00571cc0
mov ecx, dword [ebp - 0x628]
push dword [ecx + 0x40]
call fcn.0056efb0
jmp 0x5819d0
cmp esi, dword [ebp - 0x610]
je 0x581a63
push dword [esi]
call dword [sym.imp.SHLWAPI.dll_PathFindExtensionW]
push eax
lea ecx, [ebp - 0x630]
call fcn.00402cd0
mov byte [ebp - 4], 4
push str..pdf
push dword [ebp - 0x630]
call fcn.00535e6f
add esp, 8
test eax, eax
je 0x581a37
push 0
mov edx, 0x103d01
mov ecx, ebx
call fcn.00574b30
add esp, 4
mov dword [ebp - 0x648], 0xa63
lea eax, [ebp - 0x648]
push 0x5fd754
push eax
call fcn.00539115
mov byte [ebp - 4], 2
or ecx, 0xffffffff
mov edx, dword [ebp - 0x630]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x581a5b
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
add esi, 4
jmp 0x5819d0
sub esp, 0xc
lea eax, [ebp - 0x624]
mov ecx, esp
push eax
call fcn.00403070
mov ecx, ebx
call fcn.00581260
test al, al
je 0x581a9a
push 0x5fd754
lea eax, [ebp - 0x64c]
mov dword [ebp - 0x64c], 0xa6a
push eax
call fcn.00539115
mov esi, dword [ebp - 0x610]
sub esi, dword [ebp - 0x624]
sar esi, 2
cmp esi, 1
jbe 0x581b33
lea eax, [ebx + 0x4b30]
mov ecx, ebx
push eax
call fcn.00574a70
add esp, 4
test esi, esi
jne 0x581ad1
push str.invalid_vector_T__subscript
call fcn.00569015
mov eax, dword [ebp - 0x624]
mov eax, dword [eax]
sub eax, 0x10
push eax
call fcn.004039f0
add eax, 0x10
add esp, 4
mov dword [ebp - 0x610], eax
lea ecx, [ebp - 0x624]
mov byte [ebp - 4], 5
call fcn.00403790
lea eax, [ebp - 0x610]
push eax
lea ecx, [ebp - 0x624]
call fcn.004084c0
mov byte [ebp - 4], 2
or ecx, 0xffffffff
mov edx, dword [ebp - 0x610]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x581b33
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
sub esp, 8
lea ecx, [ebp - 0x60c]
call fcn.005788f0
lea eax, [ebp - 0x548]
mov byte [ebp - 4], 6
push eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [ebp - 0x550]
lea ecx, [ebp - 0x550]
mov dword [ebp - 0x518], 1
call dword [eax + 0x14]
mov esi, dword [ebp - 0x614]
test esi, esi
je 0x581b97
lea eax, [ebp - 0x548]
push eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [ebp - 0x550]
lea ecx, [ebp - 0x550]
mov dword [ebp - 0x520], esi
call dword [eax + 0x14]
lea eax, [ebp - 0x624]
push eax
lea ecx, [ebp - 0x684]
call fcn.00403070
lea eax, [ebp - 0x548]
mov byte [ebp - 4], 7
push eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
lea eax, [ebp - 0x684]
push eax
lea ecx, [ebp - 0x530]
call fcn.00403120
mov eax, dword [ebp - 0x550]
lea ecx, [ebp - 0x550]
mov byte [ebp - 0x524], 0
call dword [eax + 0x14]
lea ecx, [ebp - 0x684]
mov byte [ebp - 4], 6
call fcn.00403890
lea ecx, [ebp - 0x60c]
call fcn.00577fa0
cmp eax, 1
je 0x581c1c
push 0x5fd754
lea eax, [ebp - 0x650]
mov dword [ebp - 0x650], 0xa80
push eax
call fcn.00539115
inc dword [ebx + 0x4b2c]
mov ecx, ebx
call fcn.00587a30
sub esp, 0xc
lea eax, [ebp - 0x624]
mov ecx, esp
push eax
call fcn.00403070
push esi
call fcn.00581380
push edi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
lea ecx, [ebp - 0x60c]
mov byte [ebp - 4], 2
call fcn.00578820
lea ecx, [ebp - 0x624]
call fcn.00403890
add edi, 0xfffffff0
mov byte [ebp - 4], 0
or ecx, 0xffffffff
lea eax, [edi + 0xc]
lock xadd dword [eax], ecx
dec ecx
mov esi, dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
test ecx, ecx
jg 0x5815a0
mov ecx, dword [edi]
push edi
mov eax, dword [ecx]
call dword [eax + 4]
jmp 0x5815a0
lea ecx, [ebx + 0x4bb8]
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ecx]
call dword [eax + 0x14]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x18]
xor ecx, ebp
call fcn.00535334
mov esp, ebp
pop ebp
ret 4