Function at 0x4013c3
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0xec
mov dword [ebp - 0xe4], 0
mov eax, dword [ebp + 8]
mov dword [esp], eax
call sub.cygwin1.dll_opendir
mov dword [ebp - 0xdc], eax
test eax, eax
jne 0x4016f6
mov edx, dword [ebp + 8]
mov dword [esp + 4], edx
mov dword [esp], str.could_not_chdir_to__s_n
call fcn.00401050
mov eax, 0
jmp 0x401726
mov ebx, dword [ebp - 0xe0]
add ebx, 0x14
mov esi, ebx
mov edi, 0x405033
mov ecx, 2
cld
repe cmpsb byte [esi], byte es:[edi]
seta dl
setb al
cmp dl, al
je 0x4016f6
mov esi, ebx
mov edi, 0x405035
mov ecx, 3
repe cmpsb byte [esi], byte es:[edi]
seta dl
setb al
cmp dl, al
je 0x4016f6
test byte [0x406010], 2
jne 0x4014a0
call sub.cygwin1.dll___getreent
mov edx, dword [0x406018]
movsx edx, byte [edx + str.__]
mov dword [esp + 8], edx
mov dword [esp + 4], str._rBuilding_file_list__c
mov eax, dword [eax + 0xc]
mov dword [esp], eax
call sub.cygwin1.dll_fprintf
mov ecx, dword [0x406018]
lea edx, [ecx + 1]
mov eax, edx
test edx, edx
jns 0x401495
lea eax, [ecx + 4]
and eax, 0xfffffffc
sub edx, eax
mov dword [0x406018], edx
mov dword [esp], 0x38
call sub.cygwin1.dll_malloc
mov ebx, eax
test eax, eax
jne 0x4014d8
mov dword [esp], str.out_of_memory__n
call fcn.00401050
mov ecx, dword [ebp - 0xdc]
mov dword [esp], ecx
call sub.cygwin1.dll_closedir
mov dword [esp], 1
call sub.cygwin1.dll_exit
mov edx, dword [ebp + 0xc]
mov eax, dword [edx]
mov dword [ebx + 0x34], eax
mov dword [ebx + 0x18], 0
mov dword [ebx + 0x20], 0
mov dword [ebx + 0x24], 0
mov dword [ebx + 0x14], 0
mov dword [ebx + 0x10], 0
mov dword [ebx + 0x30], 0
mov dword [ebx + 0x2c], 0
mov esi, 0xffffffff
mov edi, dword [ebp + 8]
mov al, 0
cld
mov ecx, esi
repne scasb al, byte es:[edi]
mov edx, ecx
not edx
mov ecx, dword [ebp - 0xe0]
lea edi, [ecx + 0x14]
mov ecx, esi
repne scasb al, byte es:[edi]
not ecx
add ecx, edx
mov dword [esp], ecx
call sub.cygwin1.dll_malloc
mov dword [ebx], eax
test eax, eax
jne 0x401571
mov dword [esp], str.out_of_memory__n
call fcn.00401050
mov dword [esp], ebx
call sub.cygwin1.dll_free
mov eax, dword [ebp - 0xdc]
mov dword [esp], eax
call sub.cygwin1.dll_closedir
mov dword [esp], 1
call sub.cygwin1.dll_exit
mov edx, dword [ebp + 8]
mov dword [esp + 4], edx
mov eax, dword [ebx]
mov dword [esp], eax
call sub.cygwin1.dll_strcpy
mov esi, 0xffffffff
mov edi, dword [ebp + 8]
mov dl, 0
cld
mov ecx, esi
mov al, dl
repne scasb al, byte es:[edi]
not ecx
mov eax, ecx
sub eax, 2
js 0x4015b8
mov ecx, dword [ebp + 8]
cmp byte [ecx + eax], 0x2f
je 0x4015b8
mov edi, dword [ebx]
mov ecx, esi
mov al, dl
repne scasb al, byte es:[edi]
not ecx
mov edx, dword [ebx]
mov word [ecx + edx - 1], 0x2f
mov eax, dword [ebp - 0xe0]
add eax, 0x14
mov dword [esp + 4], eax
mov eax, dword [ebx]
mov dword [esp], eax
call sub.cygwin1.dll_strcat
mov eax, dword [ebx]
mov dword [esp], eax
call fcn.004011b7
mov ecx, edx
or ecx, eax
jne 0x4015ff
test byte [0x406010], 0x20
je 0x4015ff
mov eax, dword [ebx]
mov dword [esp], eax
call sub.cygwin1.dll_free
mov dword [esp], ebx
call sub.cygwin1.dll_free
jmp 0x4016f6
lea eax, [ebp - 0x78]
mov dword [esp + 4], eax
mov eax, dword [ebx]
mov dword [esp], eax
call sub.cygwin1.dll__stat64
cmp eax, 0xffffffff
jne 0x40162c
mov eax, dword [ebx]
mov dword [esp], eax
call sub.cygwin1.dll_free
mov dword [esp], ebx
call sub.cygwin1.dll_free
jmp 0x4016f6
lea eax, [ebp - 0xd8]
mov dword [esp + 4], eax
mov eax, dword [ebx]
mov dword [esp], eax
call sub.cygwin1.dll__lstat64
cmp eax, 0xffffffff
jne 0x40165c
mov eax, dword [ebx]
mov dword [esp], eax
call sub.cygwin1.dll_free
mov dword [esp], ebx
call sub.cygwin1.dll_free
jmp 0x4016f6
mov eax, dword [ebp - 0x68]
and eax, 0xf000
cmp eax, 0x4000
jne 0x4016b5
mov eax, dword [0x406010]
test al, 1
je 0x4016a1
test al, 8
jne 0x40168a
mov eax, dword [ebp - 0xc8]
and eax, 0xf000
cmp eax, 0xa000
je 0x4016a1
mov eax, dword [ebp + 0xc]
mov dword [esp + 4], eax
mov eax, dword [ebx]
mov dword [esp], eax
call fcn.004013c3
add dword [ebp - 0xe4], eax
mov eax, dword [ebx]
mov dword [esp], eax
call sub.cygwin1.dll_free
mov dword [esp], ebx
call sub.cygwin1.dll_free
jmp 0x4016f6
mov eax, dword [ebp - 0xc8]
and eax, 0xf000
cmp eax, 0x8000
je 0x4016d7
cmp eax, 0xa000
jne 0x4016e4
test byte [0x406010], 8
je 0x4016e4
mov edx, dword [ebp + 0xc]
mov dword [edx], ebx
inc dword [ebp - 0xe4]
jmp 0x4016f6
mov eax, dword [ebx]
mov dword [esp], eax
call sub.cygwin1.dll_free
mov dword [esp], ebx
call sub.cygwin1.dll_free
mov ecx, dword [ebp - 0xdc]
mov dword [esp], ecx
call sub.cygwin1.dll_readdir
mov dword [ebp - 0xe0], eax
test eax, eax
jne 0x40140f
mov eax, dword [ebp - 0xdc]
mov dword [esp], eax
call sub.cygwin1.dll_closedir
mov eax, dword [ebp - 0xe4]
add esp, 0xec
pop ebx
pop esi
pop edi
pop ebp
ret