Function at 0x4a1120
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
mov edi, edx
sub esp, 0x28c
mov edx, dword [eax]
mov dword [ebp - 0x274], edx
mov eax, dword [edx]
add eax, 1
cmp eax, 1
ja 0x4a1251
mov eax, dword [ebp - 0x274]
cmp dword [eax + 4], 2
jne 0x4a1240
mov edx, dword [eax + 0xc]
lea esi, [ebp - 0x274]
mov dword [ebp - 0x27c], esi
cmp word [eax + edx + 2], 0x3a
je 0x4a1290
mov eax, dword [ebp - 0x27c]
lea esi, [ebp - 0x270]
mov dword [esp], esi
mov dword [esp + 4], eax
call fcn.0055d120
mov ecx, esi
call fcn.00665e50
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
sub esp, 4
cmp eax, 0xffffffff
je 0x4a1260
test edi, edi
mov edx, dword [ebp - 0x270]
mov ecx, 1
je 0x4a11bd
mov byte [edi], cl
cmp eax, 0xffffffff
je 0x4a13d1
shr eax, 4
mov ebx, eax
and ebx, 1
mov eax, dword [edx]
test eax, eax
je 0x4a1225
cmp eax, 0xffffffff
je 0x4a11dc
lock sub dword [edx], 1
mov edx, dword [ebp - 0x270]
je 0x4a1225
mov eax, dword [ebp - 0x274]
mov edx, dword [eax]
test edx, edx
je 0x4a1203
cmp edx, 0xffffffff
je 0x4a11f9
lock sub dword [eax], 1
mov eax, dword [ebp - 0x274]
je 0x4a1203
lea esp, [ebp - 0xc]
mov eax, ebx
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [esp], eax
mov dword [esp + 8], 4
mov dword [esp + 4], 2
call fcn.004a4c50
lea esp, [ebp - 0xc]
mov eax, ebx
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [esp + 8], 4
mov dword [esp + 4], 2
mov dword [esp], edx
call fcn.004a4c50
jmp 0x4a11dc
lea eax, [ebp - 0x274]
mov dword [ebp - 0x27c], eax
jmp 0x4a116f
lock add dword [edx], 1
jmp 0x4a1144
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 5
mov edx, dword [ebp - 0x270]
sete bl
cmp eax, 0x20
sete al
or bl, al
jne 0x4a1310
test edi, edi
je 0x4a11c5
mov byte [edi], 0
jmp 0x4a11c5
mov edx, dword [eax]
mov ecx, 4
cmp edx, 1
ja 0x4a12b8
mov esi, dword [eax + 8]
mov ecx, 4
mov edx, 2
mov ebx, 2
and esi, 0x7fffffff
cmp ecx, esi
jbe 0x4a12e4
lea eax, [ebp - 0x274]
mov dword [esp], ecx
mov dword [esp + 4], 1
mov ecx, eax
mov dword [ebp - 0x27c], eax
call fcn.005ab710
mov eax, dword [ebp - 0x274]
sub esp, 8
mov edx, dword [eax + 4]
mov ebx, edx
mov ecx, dword [eax + 0xc]
add edx, 1
lea ebx, [eax + ebx*2]
mov dword [eax + 4], edx
lea eax, [eax + edx*2]
mov esi, 0x5c
xor edx, edx
mov word [ebx + ecx], si
mov word [eax + ecx], dx
jmp 0x4a116f
mov dword [ebp - 0x26c], edx
mov eax, dword [edx]
add eax, 1
cmp eax, 1
jbe 0x4a1345
lock add dword [edx], 1
jmp 0x4a1345
lea ecx, [ebp - 0x26c]
mov dword [esp], 1
call fcn.005acba0
sub esp, 4
mov edx, 0x5c
lea ecx, [ebp - 0x26c]
mov dword [esp + 4], 1
mov word [esp], dx
call fcn.00667010
sub esp, 8
test al, al
mov byte [ebp - 0x27d], al
jne 0x4a1330
mov eax, 0x3a
lea ecx, [ebp - 0x26c]
mov dword [esp + 4], 1
mov word [esp], ax
call fcn.00667010
sub esp, 8
test al, al
je 0x4a1400
mov eax, dword [ebp - 0x26c]
mov edx, dword [eax]
test edx, edx
je 0x4a13e0
cmp edx, 0xffffffff
je 0x4a13b0
lock sub dword [eax], 1
mov eax, dword [ebp - 0x26c]
je 0x4a13e0
nop
cmp byte [ebp - 0x27d], 0
jne 0x4a1441
test edi, edi
mov edx, dword [ebp - 0x270]
je 0x4a13d1
mov byte [edi], 0
xor ebx, ebx
jmp 0x4a11c5
xor ebx, ebx
jmp 0x4a11c5
mov dword [esp + 8], 4
mov dword [esp + 4], 2
mov dword [esp], eax
call fcn.004a4c50
jmp 0x4a13b0
lea ecx, [ebp - 0x26c]
call fcn.00665e50
lea edx, [ebp - 0x268]
mov dword [esp], eax
mov dword [esp + 4], edx
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
sub esp, 8
cmp eax, 0xffffffff
je 0x4a1391
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_FindClose]
sub esp, 4
mov byte [ebp - 0x27d], bl
jmp 0x4a1391
test edi, edi
mov eax, dword [ebp - 0x268]
mov edx, dword [ebp - 0x270]
je 0x4a11b4
cmp eax, 0xffffffff
setne cl
jmp 0x4a11b2