Function at 0x40c890
Capabilities:
Create directory
Move file
Set file attributes

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x5a6e00
mov eax, dword fs:[0]
push eax
sub esp, 0x30
push ebx
push esi
push edi
mov eax, dword [0x6336a0]
xor eax, esp
push eax
lea eax, [esp + 0x40]
mov dword fs:[0], eax
test edx, edx
jne 0x40c8c4
xor eax, eax
jmp 0x40c8df
mov eax, edx
lea esi, [eax + 2]
lea esp, [esp]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x40c8d0
sub eax, esi
sar eax, 1
push eax
push edx
mov ecx, 0x63c664
call fcn.00402270
push str._tglib
lea eax, [esp + 0x18]
push 0x63c664
push eax
call fcn.00401ba0
add esp, 0xc
push eax
mov ecx, 0x63c668
mov dword [esp + 0x4c], 0
call fcn.00402330
or ebx, 0xffffffff
mov dword [esp + 0x48], ebx
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
mov edx, ebx
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40c93b
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push 0x5d6140
lea ecx, [esp + 0x18]
push 0x63c664
push ecx
call fcn.00401ba0
add esp, 0xc
push eax
mov ecx, 0x63c680
mov dword [esp + 0x4c], 1
call fcn.00402330
mov dword [esp + 0x48], ebx
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
mov ecx, ebx
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40c988
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push str.lrcs
lea ecx, [esp + 0x18]
push 0x63c664
push ecx
call fcn.00401ba0
add esp, 0xc
push eax
mov ecx, 0x63c66c
mov dword [esp + 0x4c], 2
call fcn.00402330
mov dword [esp + 0x48], ebx
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
mov ecx, ebx
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40c9d5
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [0x63c668]
push eax
mov edi, eax
call fcn.0044adc0
mov esi, dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
add esp, 4
test eax, eax
jne 0x40c9f4
push 0
push edi
call esi
mov edi, dword [0x63c66c]
push edi
call fcn.0044adc0
add esp, 4
test eax, eax
jne 0x40ca0b
push eax
push edi
call esi
mov edi, dword [0x63c680]
push edi
call fcn.0044adc0
add esp, 4
test eax, eax
jne 0x40ca22
push eax
push edi
call esi
mov ecx, dword [0x63c668]
push 2
push ecx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
lea ecx, [esp + 0x28]
call fcn.0055d17f
mov dword [esp + 0x48], 3
mov edx, dword [0x63c664]
push edx
lea edi, [esp + 0x2c]
mov ecx, 0x5d6160
call fcn.0044b930
xor esi, esi
add esp, 4
cmp dword [esp + 0x30], esi
jle 0x40cba0
mov bl, 5
jmp 0x40ca70
push 0x5d616c
lea eax, [esp + 0x24]
push 0x63c680
push eax
call fcn.00401ba0
add esp, 0xc
test esi, esi
mov byte [esp + 0x48], 4
jl 0x40cd20
cmp esi, dword [esp + 0x30]
jge 0x40cd20
mov ecx, dword [esp + 0x2c]
lea ecx, [ecx + esi*4]
push ecx
push eax
lea edx, [esp + 0x24]
push edx
call fcn.00401ae0
add esp, 0xc
mov edi, eax
push 0x5d616c
lea eax, [esp + 0x1c]
push 0x63c664
push eax
mov byte [esp + 0x54], bl
call fcn.00401ba0
add esp, 0xc
mov byte [esp + 0x48], 6
cmp esi, dword [esp + 0x30]
jge 0x40cd20
mov ecx, dword [esp + 0x2c]
lea ecx, [ecx + esi*4]
push ecx
push eax
lea edx, [esp + 0x1c]
push edx
call fcn.00401ae0
mov ecx, dword [edi]
mov eax, dword [eax]
add esp, 0xc
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileW]
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40cb22
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x48], bl
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40cb46
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x48], 4
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40cb6b
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x48], 3
mov eax, dword [esp + 0x20]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40cb90
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
add esi, 1
cmp esi, dword [esp + 0x30]
jl 0x40ca70
or ebx, 0xffffffff
mov ecx, dword [0x63c664]
push ecx
lea edi, [esp + 0x2c]
mov ecx, 0x5d6170
call fcn.0044b930
xor esi, esi
add esp, 4
cmp dword [esp + 0x30], esi
jle 0x40cd00
mov bl, 8
jmp 0x40cbd0
push 0x5d616c
lea edx, [esp + 0x28]
push 0x63c680
push edx
call fcn.00401ba0
add esp, 0xc
test esi, esi
mov byte [esp + 0x48], 7
jl 0x40cd20
cmp esi, dword [esp + 0x30]
jge 0x40cd20
mov ecx, dword [esp + 0x2c]
lea ecx, [ecx + esi*4]
push ecx
push eax
lea edx, [esp + 0x20]
push edx
call fcn.00401ae0
add esp, 0xc
mov edi, eax
push 0x5d616c
lea eax, [esp + 0x20]
push 0x63c664
push eax
mov byte [esp + 0x54], bl
call fcn.00401ba0
add esp, 0xc
mov byte [esp + 0x48], 9
cmp esi, dword [esp + 0x30]
jge 0x40cd20
mov ecx, dword [esp + 0x2c]
lea ecx, [ecx + esi*4]
push ecx
push eax
lea edx, [esp + 0x28]
push edx
call fcn.00401ae0
mov ecx, dword [edi]
mov eax, dword [eax]
add esp, 0xc
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileW]
mov eax, dword [esp + 0x20]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40cc82
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x48], bl
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40cca6
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x48], 7
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40cccb
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x48], 3
mov eax, dword [esp + 0x24]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40ccf0
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
add esi, 1
cmp esi, dword [esp + 0x30]
jl 0x40cbd0
or ebx, 0xffffffff
lea ecx, [esp + 0x28]
mov dword [esp + 0x48], ebx
call fcn.0055d21d
mov ecx, dword [esp + 0x40]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
jmp fcn.00555520