Function at 0x496bfc
Capabilities:
Set current directory

Disassembly:
push 0xec
mov eax, 0x530278
call fcn.00527194
mov dword [ebp - 0xdc], ecx
mov edi, dword [ebp + 8]
xor ebx, ebx
mov esi, dword [ebp + 0xc]
push 0xf
pop eax
mov dword [ebp - 0xf4], edi
mov dword [ebp - 0xec], ebx
mov byte [ebp - 0xd1], bl
mov dword [ebp - 0x60], ebx
mov dword [ebp - 0x5c], eax
mov byte [ebp - 0x70], bl
mov dword [ebp - 4], ebx
mov dword [ebp - 0x48], ebx
mov dword [ebp - 0x44], eax
mov byte [ebp - 0x58], bl
sub esp, 0x18
mov byte [ebp - 4], 1
mov ecx, esp
push esi
call fcn.0047cac3
call fcn.0049746a
test al, al
mov eax, 0x43d0b0
jne 0x496c65
mov eax, 0x43d0b8
push esi
push eax
push edi
call fcn.004c84a0
mov eax, dword [0x54fca8]
add esp, 0xc
mov esi, dword [ebp - 0xdc]
mov al, byte [eax + 0xe]
test al, al
je 0x496c9b
push 0x7b
mov ecx, esi
call fcn.004678e1
test eax, eax
je 0x496c9b
push 0x43d0bc
mov ecx, edi
call fcn.004c8444
lea ecx, [ebp - 0x88]
call fcn.004c9118
push eax
lea ecx, [ebp - 0x70]
call fcn.0047c9f5
lea ecx, [ebp - 0x88]
call fcn.0047c9d0
cmp dword [ebp - 0x60], 0
jne 0x496ce0
cmp dword [ebp - 0x5c], 0x10
lea eax, [ebp - 0x70]
jb 0x496ccc
mov eax, dword [ebp - 0x70]
push eax
push 0x3f8
xor edx, edx
xor ecx, ecx
call fcn.004c885f
jmp 0x497452
lea ecx, [ebp - 0x88]
call fcn.004c9220
push eax
lea ecx, [ebp - 0x58]
call fcn.0047c9f5
lea ecx, [ebp - 0x88]
call fcn.0047c9d0
push 0x1f
mov ecx, esi
call fcn.004678e1
test eax, eax
jne 0x496d4f
sub esp, 0x18
lea eax, [ebp - 0x58]
mov ecx, esp
push eax
call fcn.0047cafa
call fcn.0049746a
test al, al
lea eax, [ebp - 0x58]
je 0x496d37
cmp dword [ebp - 0x44], 0x10
jb 0x496d2f
mov eax, dword [ebp - 0x58]
push eax
push 0x43d0cc
jmp 0x496d46
cmp dword [ebp - 0x44], 0x10
jb 0x496d40
mov eax, dword [ebp - 0x58]
push eax
push 0x43d0d8
push edi
call fcn.004c84a0
add esp, 0xc
sub esp, 0x18
lea eax, [ebp - 0x58]
mov ecx, esp
push eax
call fcn.0047cafa
call fcn.0049746a
test al, al
lea eax, [ebp - 0x58]
je 0x496d79
cmp dword [ebp - 0x44], 0x10
jb 0x496d72
mov eax, dword [ebp - 0x58]
mov ecx, 0x43d0e4
jmp 0x496d87
cmp dword [ebp - 0x44], 0x10
jb 0x496d82
mov eax, dword [ebp - 0x58]
mov ecx, 0x43d0f0
push eax
push ecx
push edi
call fcn.004c84a0
add esp, 0xc
cmp word [esi + 0x50], bx
jle 0x49729c
xor eax, eax
mov word [esi + 0x50], ax
mov eax, dword [esi + 0x14c]
movzx eax, word [eax]
mov word [esi + 0x52], ax
jmp 0x49729c
xor eax, eax
mov dword [ebp - 0x14], 0xf
mov dword [ebp - 0x18], eax
mov byte [ebp - 0x28], al
mov byte [ebp - 4], 2
mov al, byte [ebx]
cmp al, 0x2d
je 0x496dfe
cmp al, 0x2f
je 0x496dfe
cmp byte [ebp - 0xd1], 0
jne 0x496e16
mov ecx, dword [esi + 0xbc]
test ecx, ecx
je 0x496e16
add ecx, 0x7c
mov edx, ebx
call fcn.00490ca7
test al, al
je 0x496e16
mov byte [ebp - 0xd1], 1
jmp 0x497290
lea eax, [ebx + 1]
lea ecx, [ebp - 0xd8]
mov dword [ebp - 0xd8], eax
call fcn.004990a8
test eax, eax
jne 0x496e45
sub esp, 0x18
mov ecx, esp
push ebx
call fcn.0047cac3
call fcn.0049746a
push ebx
test al, al
je 0x496e32
push 0x43d0b0
jmp 0x496e37
push 0x43d0b8
push edi
call fcn.004c84a0
add esp, 0xc
jmp 0x497290
mov ecx, dword [ebp - 0xdc]
imul eax, eax, 0xc
mov esi, dword [eax + 0x40ba08]
movzx eax, word [eax + 0x40ba04]
push eax
lea eax, [ebp - 0xd8]
push eax
call fcn.004974a5
test eax, eax
je 0x496e77
push ebx
push eax
xor edx, edx
xor ecx, ecx
call fcn.004c885f
cmp esi, 0x18
jg 0x497141
cmp esi, 0x17
jge 0x49728a
cmp esi, 2
je 0x497157
cmp esi, 0x12
je 0x496eb0
cmp esi, 0x13
jle 0x496ea5
cmp esi, 0x15
jle 0x49728a
mov esi, dword [ebp - 0xd8]
jmp 0x49722e
mov eax, dword [0x54fca8]
mov al, byte [eax + 0xe]
test al, al
je 0x496ea5
mov ecx, dword [ebp - 0xdc]
push 0x7b
call fcn.004678e1
test eax, eax
jne 0x496ea5
mov edx, ebx
lea ecx, [edx + 1]
mov al, byte [edx]
inc edx
test al, al
jne 0x496ed2
mov eax, dword [ebp - 0xd8]
sub edx, ecx
push eax
lea ecx, [ebp - 0x40]
mov dword [ebp - 0xe0], edx
mov dword [ebp - 0xe4], eax
call fcn.0047cac3
lea edx, [ebp - 0x40]
mov byte [ebp - 4], 5
lea ecx, [ebp - 0xb8]
call fcn.004c8f01
lea ecx, [ebp - 0x40]
mov byte [ebp - 4], 7
call fcn.0047c9d0
mov esi, 0x10000
push esi
call fcn.00526210
mov edi, eax
mov dword [ebp - 0xf8], edi
push esi
mov byte [ebp - 4], 8
call fcn.00526210
mov esi, eax
mov dword [ebp - 0xe8], esi
push 0x10000
mov byte [ebp - 4], 9
call fcn.00526210
mov dword [ebp - 0xd8], eax
push 0x10000
mov byte [ebp - 4], 0xa
call fcn.00526210
add esp, 0x10
mov dword [ebp - 0xf0], eax
cmp dword [ebp - 0xa4], 8
lea ecx, [ebp - 0xb8]
jb 0x496f79
mov ecx, dword [ebp - 0xb8]
mov edx, 0x8000
push edx
push eax
push edx
push dword [ebp - 0xd8]
push edx
push edi
push edx
push esi
push ecx
call fcn.0050b234
mov eax, dword [ebp - 0xd8]
add esp, 0x24
mov ecx, 0x43d0f8
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x496fc7
test dx, dx
je 0x496fc1
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x496fc7
add eax, 4
add ecx, 4
test dx, dx
jne 0x496f9f
xor ecx, ecx
mov eax, ecx
jmp 0x496fce
sbb eax, eax
or eax, 1
xor ecx, ecx
test eax, eax
je 0x4970e9
xor eax, eax
mov dword [ebp - 0x90], ecx
mov dword [ebp - 0x8c], 7
mov word [ebp - 0xa0], ax
mov ecx, esi
mov byte [ebp - 4], 0xc
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, word [ebp - 0xec]
jne 0x496ff8
sub ecx, edx
sar ecx, 1
je 0x497019
push esi
lea ecx, [ebp - 0xa0]
call fcn.0049932c
mov ecx, edi
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, word [ebp - 0xec]
jne 0x49701e
sub ecx, edx
sar ecx, 1
je 0x49703f
push edi
lea ecx, [ebp - 0xa0]
call fcn.0049932c
push dword [ebp - 0xd8]
lea ecx, [ebp - 0xa0]
call fcn.0049932c
push 0x43d100
lea ecx, [ebp - 0xa0]
call fcn.0049932c
push dword [ebp - 0xf0]
lea ecx, [ebp - 0xa0]
call fcn.0049932c
mov ecx, ebx
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x497076
sub ecx, edx
push ecx
push ebx
lea ecx, [ebp - 0x28]
call fcn.0047df1d
lea edx, [ebp - 0xa0]
lea ecx, [ebp - 0x88]
call fcn.004c8fac
mov byte [ebp - 4], 0xd
cmp dword [eax + 0x14], 0x10
mov ecx, dword [eax + 0x10]
jb 0x4970a9
mov eax, dword [eax]
push ecx
push eax
lea ecx, [ebp - 0x28]
call fcn.0047dfc7
lea ecx, [ebp - 0x88]
call fcn.0047c9d0
cmp dword [ebp - 0x14], 0x10
lea ebx, [ebp - 0x28]
jb 0x4970ca
mov ebx, dword [ebp - 0x28]
lea eax, [ebp - 0x28]
jb 0x4970d2
mov eax, dword [ebp - 0x28]
add eax, dword [ebp - 0xe0]
lea ecx, [ebp - 0xa0]
mov dword [ebp - 0xe4], eax
call fcn.0047de9f
mov eax, dword [ebp - 0xf0]
test eax, eax
je 0x4970fa
push eax
call fcn.005261fb
pop ecx
mov eax, dword [ebp - 0xd8]
test eax, eax
je 0x49710b
push eax
call fcn.005261fb
pop ecx
test esi, esi
je 0x497116
push esi
call fcn.005261fb
pop ecx
test edi, edi
je 0x497121
push edi
call fcn.005261fb
pop ecx
lea ecx, [ebp - 0xb8]
mov byte [ebp - 4], 2
call fcn.0047de9f
mov esi, dword [ebp - 0xe4]
mov edi, dword [ebp - 0xf4]
jmp 0x49722e
cmp esi, 0x4f
je 0x497157
lea eax, [esi - 0x74]
cmp eax, 0xd
jbe 0x49728a
jmp 0x496ea5
mov esi, dword [ebp - 0xd8]
push esi
call dword [sym.imp.SHLWAPI.dll_PathIsRelativeA]
test eax, eax
je 0x49722e
xor eax, eax
mov dword [ebp - 0x2c], 0xf
mov dword [ebp - 0x30], eax
mov byte [ebp - 0x40], al
mov eax, esi
mov byte [ebp - 4], 3
sub eax, ebx
lea ecx, [ebp - 0x88]
push esi
mov dword [ebp - 0xe0], eax
call fcn.0047cac3
lea edx, [ebp - 0x88]
mov byte [ebp - 4], 4
lea ecx, [ebp - 0xd0]
call fcn.004c905f
push eax
lea ecx, [ebp - 0x40]
call fcn.0047c9f5
lea ecx, [ebp - 0xd0]
call fcn.0047c9d0
lea ecx, [ebp - 0x88]
mov byte [ebp - 4], 3
call fcn.0047c9d0
mov ecx, ebx
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4971d2
sub ecx, edx
push ecx
push ebx
lea ecx, [ebp - 0x28]
call fcn.0047df1d
mov esi, dword [ebp - 0xe0]
lea ecx, [ebp - 0x28]
push esi
call fcn.00490702
cmp dword [ebp - 0x2c], 0x10
lea eax, [ebp - 0x40]
jb 0x497200
mov eax, dword [ebp - 0x40]
push dword [ebp - 0x30]
lea ecx, [ebp - 0x28]
push eax
call fcn.0047dfc7
cmp dword [ebp - 0x14], 0x10
lea ebx, [ebp - 0x28]
jb 0x497218
mov ebx, dword [ebp - 0x28]
lea eax, [ebp - 0x28]
jb 0x497220
mov eax, dword [ebp - 0x28]
lea ecx, [ebp - 0x40]
mov byte [ebp - 4], 2
add esi, eax
call fcn.0047c9d0
push esi
push ebx
call fcn.00527ca0
pop ecx
pop ecx
test eax, eax
jne 0x497267
push ebx
mov ebx, 0x43d0b8
push ebx
push edi
call fcn.004c84a0
sub esp, 0xc
mov ecx, esp
push esi
call fcn.0047cac3
call fcn.0049746a
push esi
test al, al
je 0x497264
push 0x43d0b0
jmp 0x497281
push ebx
jmp 0x497281
sub esp, 0x18
mov ecx, esp
push ebx
call fcn.0047cac3
call fcn.0049746a
push ebx
test al, al
jne 0x49725d
push 0x43d0b8
push edi
call fcn.004c84a0
add esp, 0xc
mov esi, dword [ebp - 0xdc]
lea ecx, [ebp - 0x28]
mov byte [ebp - 4], 1
call fcn.0047c9d0
mov ecx, esi
call fcn.0049687a
mov ebx, eax
test ebx, ebx
jne 0x496db4
push 0x12
mov ecx, esi
call fcn.004678e1
test eax, eax
jne 0x4973f4
push 0x7b
mov ecx, esi
call fcn.004678e1
test eax, eax
jne 0x4973f4
mov ecx, dword [esi + 0xbc]
test ecx, ecx
je 0x4972e0
call fcn.00495c1f
jmp 0x4972e4
xor ebx, ebx
mov eax, ebx
push eax
lea ecx, [ebp - 0x88]
call fcn.0047cac3
lea edx, [ebp - 0x88]
mov byte [ebp - 4], 0xe
lea ecx, [ebp - 0xb8]
call fcn.004c8f01
lea ecx, [ebp - 0x88]
mov byte [ebp - 4], 0x10
call fcn.0047c9d0
push 0x10000
call fcn.00526210
mov esi, eax
pop ecx
mov dword [ebp - 0xe8], esi
cmp dword [ebp - 0xa4], 8
lea eax, [ebp - 0xb8]
jb 0x49733c
mov eax, dword [ebp - 0xb8]
push ebx
push ebx
push 0x8000
push esi
push ebx
push ebx
push ebx
push ebx
push eax
call fcn.0050b234
add esp, 0x24
mov eax, esi
mov edx, 0x43d0f8
mov cx, word [eax]
cmp cx, word [edx]
jne 0x49737e
test cx, cx
je 0x49737a
mov cx, word [eax + 2]
cmp cx, word [edx + 2]
jne 0x49737e
add eax, 4
add edx, 4
test cx, cx
jne 0x497358
mov eax, ebx
jmp 0x497383
sbb eax, eax
or eax, 1
test eax, eax
je 0x4973d4
xor eax, eax
mov dword [ebp - 0x30], ebx
mov dword [ebp - 0x2c], 7
mov word [ebp - 0x40], ax
push esi
lea ecx, [ebp - 0x40]
mov byte [ebp - 4], 0x12
call fcn.0049932c
push 0x43d108
lea ecx, [ebp - 0x40]
call fcn.0049932c
cmp dword [ebp - 0x2c], 8
lea eax, [ebp - 0x40]
jb 0x4973bd
mov eax, dword [ebp - 0x40]
push eax
push 0x43d114
push edi
call fcn.004c84a0
add esp, 0xc
lea ecx, [ebp - 0x40]
call fcn.0047de9f
test esi, esi
je 0x4973df
push esi
call fcn.005261fb
pop ecx
lea ecx, [ebp - 0xb8]
mov byte [ebp - 4], 1
call fcn.0047de9f
mov esi, dword [ebp - 0xdc]
mov eax, dword [0x54fca8]
cmp byte [eax + 0xf], 0
je 0x49743f
call fcn.00495c6c
test al, al
je 0x49743f
mov ecx, dword [esi + 0xdc]
call fcn.00495c1f
sub esp, 0x18
mov esi, eax
mov ecx, esp
push esi
call fcn.0047cac3
call fcn.0049746a
push esi
test al, al
je 0x497431
push 0x43d120
jmp 0x497436
push 0x43d134
push edi
call fcn.004c84a0
add esp, 0xc
cmp dword [ebp - 0x5c], 0x10
lea eax, [ebp - 0x70]
jb 0x49744b
mov eax, dword [ebp - 0x70]
push eax
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
lea ecx, [ebp - 0x58]
call fcn.0047c9d0
lea ecx, [ebp - 0x70]
call fcn.0047c9d0
call fcn.0052713e
ret 8