Function at 0x49c560
Capabilities:
Enumerate files on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x270
mov eax, dword [0x9c48d0]
xor eax, esp
mov dword [esp + 0x26c], eax
push ebx
mov ebx, ecx
push esi
mov dword [esp + 0x10], ebx
test ebx, ebx
je 0x49c591
push ebx
call fcn.00661039
add esp, 4
jmp 0x49c593
xor eax, eax
mov dword [edi + 4], eax
mov eax, 0x6b8ff4
mov edx, ebx
call fcn.00455100
lea ecx, [esp + 0x20]
push ecx
push eax
mov dword [esp + 0x1c], eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov esi, eax
mov dword [esp + 0x1c], esi
cmp esi, 0xffffffff
jne 0x49c5e0
mov edx, dword [esp + 0x14]
push edx
call fcn.00658a01
add esp, 4
xor al, al
pop esi
pop ebx
mov ecx, dword [esp + 0x26c]
xor ecx, esp
call fcn.0065865c
mov esp, ebp
pop ebp
ret
test byte [esp + 0x20], 0x10
jne 0x49c662
push 0
lea ecx, [esp + 0x50]
call fcn.0049c230
add esp, 4
test al, al
je 0x49c662
lea eax, [esp + 0x4c]
mov edx, ebx
call fcn.00455100
lea esi, [edi + 0x298]
mov dword [esp + 0x18], eax
mov eax, dword [esi]
lea ebx, [eax + 1]
mov ecx, ebx
mov dword [esp + 0xc], eax
call fcn.0044f630
test al, al
jne 0x49c626
xor eax, eax
mov byte [eax], al
mov edx, dword [esp + 0xc]
mov ecx, dword [esi + 0xc]
mov eax, dword [esi]
lea ecx, [ecx + edx*4]
mov dword [esp + 0xc], ecx
cmp eax, edx
jbe 0x49c652
sub eax, edx
add eax, eax
add eax, eax
push eax
push ecx
add ecx, 4
push ecx
call fcn.006586a0
mov ecx, dword [esp + 0x18]
add esp, 0xc
mov edx, dword [esp + 0x18]
mov dword [esi], ebx
mov esi, dword [esp + 0x1c]
mov ebx, dword [esp + 0x10]
mov dword [ecx], edx
lea eax, [esp + 0x20]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x49c5e0
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
cmp dword [edi + 0x298], 0
jne 0x49c6a9
mov ecx, dword [esp + 0x14]
push ecx
call fcn.00658a01
add esp, 4
xor al, al
pop esi
pop ebx
mov ecx, dword [esp + 0x26c]
xor ecx, esp
call fcn.0065865c
mov esp, ebp
pop ebp
ret
mov edx, dword [edi + 0x298]
mov eax, dword [edi + 0x2a4]
push 0x401370
push 4
push edx
push eax
call fcn.00658b10
mov ecx, dword [edi + 0x298]
add esp, 0x10
push ecx
lea eax, [edi + 0x80]
call fcn.0049e720
push 0
push 1
mov eax, edi
call fcn.0049b410
mov ebx, eax
test ebx, ebx
je 0x49c75c
mov esi, dword [ebx + 4]
fldz
mov eax, dword [esi + 4]
fstp dword [esp + 0xc]
lea edx, [esp + 0xc]
push edx
push eax
call dword [sym.imp.gdiplus.dll_GdipGetImageHorizontalResolution]
test eax, eax
je 0x49c708
mov dword [esi + 8], eax
fld dword [esp + 0xc]
lea esi, [edi + 0xc]
push esi
fstp dword [edi + 0x2f0]
mov dword [esp + 0x14], esi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
dec dword [ebx + 0xc]
jne 0x49c731
lea esi, [edi + 0x24]
call fcn.00486170
mov esi, dword [esp + 0x10]
cmp dword [ebx + 0xc], 0
jne 0x49c755
cmp byte [ebx + 8], 0
je 0x49c74c
mov ecx, dword [ebx + 4]
test ecx, ecx
je 0x49c74c
mov edx, dword [ecx]
mov eax, dword [edx]
push 1
call eax
push ebx
call fcn.006590fa
add esp, 4
push esi
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov ecx, dword [esp + 0x14]
push ecx
call fcn.00658a01
mov ecx, dword [esp + 0x278]
add esp, 4
pop esi
pop ebx
xor ecx, esp
mov al, 1
call fcn.0065865c
mov esp, ebp
pop ebp
ret