Function at 0x401060
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x5c
push ebx
push esi
push edi
call entry0
test eax, eax
je 0x4013d3
push 2
call dword [0x4231c8]
cmp dword [section..share], 0
jne 0x4013d3
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x4013d3
lea eax, [esp + 0x10]
push eax
call fcn.004029c0
mov ecx, dword [esp + 0x10]
mov eax, dword [ecx - 0xc]
test eax, eax
jne 0x4010c3
lea eax, [ecx - 0x10]
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jmp 0x4013c7
jl 0x4011b1
push str._id:
push ecx
call fcn.004110d0
mov ecx, dword [esp + 0x18]
add esp, 8
test eax, eax
je 0x4011b1
sub eax, ecx
sar eax, 1
mov edi, eax
js 0x4011b1
lea ecx, [edi + 1]
mov edx, 0x4250c0
lea esi, [esp + 0x10]
call fcn.00401490
lea ecx, [edi + 4]
mov edx, esi
test eax, eax
jl 0x401143
mov esi, eax
sub esi, edi
push edx
lea eax, [esi - 4]
lea edx, [esp + 0x1c]
call fcn.004014e0
mov eax, dword [eax]
push eax
call fcn.004110ba
mov dword [0x430774], eax
add esp, 4
lea eax, [esp + 0x18]
call fcn.00401e20
lea eax, [esp + 0x10]
push eax
mov eax, esi
mov ecx, edi
call fcn.004013e0
jmp 0x401184
lea esi, [esp + 0x18]
call fcn.004014c0
mov eax, dword [eax]
push eax
call fcn.004110ba
mov dword [0x430774], eax
add esp, 4
mov eax, esi
call fcn.00401e20
mov eax, edi
lea ecx, [esp + 0x18]
lea edx, [esp + 0x10]
call fcn.00401590
lea edi, [esp + 0x10]
call fcn.004018a0
lea eax, [esp + 0x18]
call fcn.00401e20
lea ebx, [esp + 0x10]
call fcn.00401780
mov ebx, eax
call fcn.00401800
cmp dword [0x430774], 2
jl 0x4011bd
lea eax, [esp + 0x10]
call fcn.00401e20
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x10
mov dword [0x430774], 0
jmp 0x4011c1
mov ecx, dword [esp + 0x10]
push ecx
call dword [0x4231d8]
mov edx, eax
mov edi, 0x43079c
call fcn.00402980
inc dword [section..share]
lea esi, [esp + 0x24]
call fcn.00401600
lea ecx, [esp + 0x10]
push ecx
mov ecx, esi
call fcn.004016c0
lea esi, [esp + 0x14]
call fcn.004024b0
mov edx, dword [0x42fb6c]
mov eax, dword [edx + 0xc]
mov ecx, 0x42fb6c
call eax
mov edi, eax
add edi, 0x10
xor ebx, ebx
mov dword [esp + 0x18], edi
cmp dword [esp + 0x40], ebx
jbe 0x401313
push ebx
lea eax, [esp + 0x28]
call fcn.00401640
mov eax, dword [eax]
sub eax, 0x10
call fcn.00401b60
mov ecx, dword [esp + 0x14]
mov esi, eax
add esi, 0x10
push ecx
mov ecx, esi
call fcn.00406e40
mov eax, dword [esp + 0x18]
add esp, 4
lea edx, [esp + 0x44]
push edx
push 0
push eax
call dword [0x423020]
test eax, eax
je 0x401277
mov ecx, dword [esp + 0x64]
mov eax, dword [esp + 0x60]
mov edx, ecx
or edx, eax
je 0x401277
test eax, eax
jl 0x40129c
jg 0x401277
cmp ecx, 0xfa000
jbe 0x40129c
lea eax, [esi - 0x10]
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x401293
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
inc ebx
cmp ebx, dword [esp + 0x40]
jb 0x40121d
jmp 0x401313
lea ebx, [esi - 0x10]
lea eax, [edi - 0x10]
mov dword [esp + 0x20], ebx
mov dword [esp + 0x1c], eax
cmp ebx, eax
je 0x4012fa
cmp dword [eax + 0xc], 0
lea edi, [eax + 0xc]
jl 0x4012e5
mov ecx, dword [ebx]
cmp ecx, dword [eax]
jne 0x4012e5
mov eax, ebx
call fcn.00401b60
mov esi, eax
or edx, 0xffffffff
lock xadd dword [edi], edx
dec edx
test edx, edx
jg 0x4012e0
mov eax, dword [esp + 0x1c]
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea edi, [esi + 0x10]
jmp 0x4012fa
mov ebx, dword [esi - 0xc]
push esi
lea eax, [esp + 0x1c]
call fcn.004028e0
mov edi, dword [esp + 0x18]
mov ebx, dword [esp + 0x20]
lea ecx, [ebx + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x401313
mov ecx, dword [ebx]
mov eax, dword [ecx]
mov edx, dword [eax + 4]
push ebx
call edx
push edi
call dword [0x4231dc]
test eax, eax
je 0x401350
mov eax, dword [esp + 0x14]
lea esi, [esp + 0x1c]
lea ebx, [esp + 0x20]
call fcn.00402430
mov esi, dword [esp + 0x20]
test esi, esi
je 0x401349
mov eax, dword [esp + 0x14]
call fcn.00403c00
push esi
call fcn.004110c5
add esp, 4
push edi
call dword [0x423034]
mov eax, dword [esp + 0x14]
push eax
call dword [0x423034]
dec dword [section..share]
lea eax, [edi - 0x10]
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40137d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40139d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea esi, [esp + 0x24]
call fcn.00401a60
mov ecx, dword [esp + 0x24]
push ecx
call fcn.00410e21
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
add esp, 4
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x4013d3
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret 0x10