Function at 0x406550
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x620
mov eax, dword [0x42400c]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, ecx
call fcn.004012f0
mov ecx, eax
test ecx, ecx
je 0x406846
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x610], eax
test esi, esi
jne 0x40658c
xor ecx, ecx
jmp 0x4065a0
mov ecx, esi
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x406591
sub ecx, edx
sar ecx, 1
push ecx
push esi
lea ecx, [ebp - 0x610]
call fcn.00404970
sub esp, 8
lea ecx, [ebp - 0x610]
call fcn.00406d80
lea ecx, [ebp - 0x610]
call fcn.00406a60
mov esi, dword [ebp - 0x610]
xor eax, eax
push 0x100
mov word [ebp - 0x60c], ax
mov word [ebp - 0x606], ax
mov word [ebp - 0x406], ax
mov word [ebp - 0x206], ax
lea eax, [ebp - 0x206]
push eax
push 0x100
lea eax, [ebp - 0x406]
push eax
push 0x100
lea eax, [ebp - 0x606]
push eax
push 3
lea eax, [ebp - 0x60c]
push eax
push esi
call fcn.0040ddc2
add esp, 0x24
mov ecx, 0x420af8
mov eax, esi
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x40664d
test dx, dx
je 0x406649
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x40664d
add eax, 4
add ecx, 4
test dx, dx
jne 0x406627
xor eax, eax
jmp 0x406652
sbb eax, eax
or eax, 1
test eax, eax
je 0x40681a
push esi
call dword [sym.imp.SHLWAPI.dll_PathIsRelativeW]
test eax, eax
jne 0x40681a
cmp dword [esi - 0xc], eax
jl 0x40668d
push 0x421130
push esi
call fcn.00409401
add esp, 8
test eax, eax
je 0x40668d
sub eax, esi
sar eax, 1
cmp eax, 0xffffffff
jne 0x40681a
push esi
call dword [sym.imp.SHLWAPI.dll_PathGetDriveNumberW]
cmp eax, 0xffffffff
je 0x40681a
push edi
lea eax, [ebp - 0x606]
mov bl, 1
push eax
lea ecx, [ebp - 0x614]
call fcn.00404600
mov edi, 1
test edi, edi
js 0x4067f9
mov eax, dword [ebp - 0x614]
cmp edi, dword [eax - 0xc]
jge 0x4067ff
lea eax, [eax + edi*2]
push 0x5c
push eax
call fcn.0040967d
mov edi, eax
add esp, 8
test edi, edi
je 0x4067f9
mov eax, dword [ebp - 0x614]
sub edi, eax
sar edi, 1
cmp edi, 0xffffffff
je 0x4067ff
lea eax, [ebp - 0x60c]
push eax
lea ecx, [ebp - 0x618]
call fcn.00404600
lea eax, [ebp - 0x618]
push eax
lea ecx, [ebp - 0x610]
call fcn.00406860
mov edx, dword [ebp - 0x618]
or eax, 0xffffffff
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x40673b
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
inc edi
lea eax, [ebp - 0x620]
push edi
push eax
lea ecx, [ebp - 0x614]
call fcn.00406ad0
mov esi, dword [ebp - 0x610]
mov ecx, 1
mov eax, dword [eax]
sub ecx, dword [esi - 4]
mov dword [ebp - 0x61c], eax
mov eax, dword [esi - 8]
sub eax, 0x104
or ecx, eax
jge 0x406787
push 0x104
lea ecx, [ebp - 0x610]
call fcn.00404cf0
mov esi, dword [ebp - 0x610]
push dword [ebp - 0x61c]
push esi
call dword [sym.imp.SHLWAPI.dll_PathAppendW]
push dword [esi - 8]
push esi
call fcn.0040e02a
add esp, 8
test eax, eax
js 0x406850
cmp eax, dword [esi - 8]
jg 0x406850
mov dword [esi - 0xc], eax
xor ecx, ecx
mov word [esi + eax*2], cx
or eax, 0xffffffff
mov edx, dword [ebp - 0x620]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x4067d8
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
push esi
call dword [sym.imp.SHLWAPI.dll_PathIsDirectoryW]
test eax, eax
jne 0x4066b7
push eax
push esi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov bl, al
test bl, bl
jne 0x4066b7
mov eax, dword [ebp - 0x614]
lea edx, [eax - 0x10]
or eax, 0xffffffff
lock xadd dword [edx + 0xc], eax
dec eax
pop edi
test eax, eax
jg 0x40681c
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
jmp 0x40681c
xor bl, bl
add esi, 0xfffffff0
or eax, 0xffffffff
lock xadd dword [esi + 0xc], eax
dec eax
test eax, eax
jg 0x406834
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov ecx, dword [ebp - 4]
mov al, bl
pop esi
xor ecx, ebp
pop ebx
call fcn.0040805b
mov esp, ebp
pop ebp
ret
push 0x80004005
call fcn.00405840
push 0x80070057
call fcn.00405840
int3