Function at 0x42d8c0
Capabilities:
Set current directory

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
mov eax, dword [ebp + 8]
sub esp, 0xa4
cmp byte [0x51f521], 0
push ebx
mov ebx, ecx
push esi
push edi
mov dword [ebx + 0x5ec], eax
jne 0x42db1a
cmp byte [ebx + 0x630], 0
je 0x42db1a
mov eax, dword [ebp + 0xc]
mov ecx, dword [0x4fb94c]
push 0
push 1
mov dword [0x51f6c4], eax
call fcn.00401670
push 0x7f
push eax
lea eax, [esp + 0x38]
push eax
call fcn.004cc440
mov eax, dword [0x4f898c]
add esp, 0xc
inc dword [0x4fb950]
add eax, 0xe8
mov byte [esp + 0xaf], 0
mov edi, eax
mov ecx, 0x3a
mov dword [0x4f898c], eax
mov esi, 0x4fb850
rep movsd dword es:[edi], dword [esi]
push 0
mov ecx, 0x4fda88
mov dword [eax + 0x2c], 0
call fcn.0042d2d0
cmp dword [0x4fb964], 0
xorps xmm0, xmm0
movlpd qword [0x4fe0c8], xmm0
je 0x42d989
mov eax, dword [0x4fa378]
mov ecx, 0x4e3371
test eax, eax
je 0x42d982
mov eax, dword [eax]
test eax, eax
cmovne ecx, eax
push ecx
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
mov ecx, dword [0x4fa314]
mov edi, dword [0x4f8984]
mov dword [0x4f8984], 0
mov byte [0x51f521], 1
cmp ecx, dword [0x4fa318]
jne 0x42d9b9
call fcn.004065b0
mov ecx, dword [0x4fa314]
cmp ecx, dword [0x4fa310]
jb 0x42d9ce
mov eax, dword [0x4fde14]
mov dword [ecx], eax
mov ecx, dword [0x4fa314]
add ecx, 0xc
mov byte [0x4fa732], 0
mov dword [0x4fa314], ecx
mov dword [ecx], 0
mov dword [ecx + 4], str.OnExit
mov dword [ecx + 8], 0
mov esi, dword [ebx + 0x5e0]
test esi, esi
je 0x42da96
mov eax, dword [0x4f898c]
mov ecx, dword [eax + 0x9c]
mov dword [eax + 0x9c], esi
mov dword [esp + 0xc], ecx
mov ecx, dword [0x4fa314]
cmp ecx, dword [0x4fa318]
jne 0x42da2e
call fcn.004065b0
mov ecx, dword [0x4fa314]
cmp ecx, dword [0x4fa310]
jb 0x42da43
mov eax, dword [0x4fde14]
mov dword [ecx], eax
mov ecx, dword [0x4fa314]
add ecx, 0xc
mov dword [0x4fa314], ecx
mov eax, dword [esi + 8]
push 0
push 0
mov dword [ecx], eax
mov dword [ecx + 4], esi
mov dword [ecx + 8], 1
mov ecx, dword [esi + 8]
push 1
call fcn.00442f20
mov ecx, dword [0x4f898c]
sub dword [0x4fa314], 0xc
mov edx, dword [esp + 0xc]
mov dword [ecx + 0x9c], edx
test eax, eax
je 0x42da96
cmp byte [0x4fa732], 0
jne 0x42da96
mov byte [0x4fa732], 1
jmp 0x42dae7
mov byte [0x4fa732], 1
mov dword [esp + 0x18], 0
call fcn.004657c0
mov dword [esp + 0x10], eax
lea ecx, [ebx + 0x5ac]
mov eax, dword [0x51f6c4]
cdq
mov dword [esp + 0x20], eax
xor eax, eax
cmp dword [ebx + 0x5e0], eax
mov dword [esp + 0x28], 1
sete al
mov dword [esp + 0x24], edx
push eax
push 2
lea eax, [esp + 0x18]
push eax
call fcn.0049d9b0
cmp eax, 3
jne 0x42db65
sub dword [0x4fa314], 0xc
xor al, al
mov byte [0x51f521], al
mov eax, dword [ebp + 8]
cmp eax, 0xffffffff
jle 0x42db76
lea ecx, [esp + 0x30]
call fcn.004045b0
mov dword [0x4f8984], edi
mov eax, 8
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
cmp byte [0x4fa732], 0
jne 0x42db55
cmp eax, 6
jne 0x42db55
mov eax, dword [0x4fd160]
mov ecx, dword [0x51f6c4]
pop edi
pop esi
cmp byte [eax], 0
mov eax, 8
mov byte [0x4fa732], 1
cmovne ecx, dword [ebp + 0xc]
mov dword [0x51f6c4], ecx
pop ebx
mov esp, ebp
pop ebp
ret 8
push dword [ebp + 0xc]
mov byte [0x4fa732], 0
push eax
call fcn.0042db90
sub dword [0x4fa314], 0xc
mov eax, dword [ebp + 8]
mov byte [0x51f521], 0
push dword [ebp + 0xc]
mov ecx, ebx
push eax
call fcn.0042db90
int3