Function at 0x40a040
Capabilities:
Move file

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0x38
mov eax, dword [0x43d00c]
mov edi, ecx
mov ecx, edx
mov esi, edx
xor eax, ebp
mov dword [esp + 0x30], eax
call fcn.00403710
mov ebx, eax
test eax, eax
jne 0x40a0b8
mov eax, esp
push eax
push edi
call fcn.0041aa02
add esp, 8
test eax, eax
je 0x40a0cd
mov ecx, dword [0x43db8c]
mov edx, dword fs:[0x2c]
mov eax, dword [0x43fa9c]
mov ecx, dword [edx + ecx*4]
cmp eax, dword [ecx + 4]
jg 0x40a231
call fcn.0041a26c
push dword [eax]
push edi
push str.rename_file:_failed_to_read_file_status_info:__S__err:__d
push 0x43f890
call fcn.00410af0
add esp, 0x10
mov ebx, 6
mov ecx, dword [esp + 0x30]
xor ecx, ebp
call fcn.00412fa1
mov eax, ebx
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
movzx eax, word [esp + 6]
and eax, 0xf000
cmp eax, 0x8000
je 0x40a12c
mov cl, byte [ebp + 8]
movzx eax, ax
mov edx, dword fs:[0x2c]
xor cl, 1
cmp eax, 0x4000
mov eax, dword [0x43fa9c]
sete bl
or bl, cl
mov ecx, dword [0x43db8c]
mov ecx, dword [edx + ecx*4]
cmp eax, dword [ecx + 4]
jg 0x40a274
test bl, bl
je 0x40a2ba
push str.rename_file:_proceeding_to_rename_the_directory
push 0x43f890
call fcn.00410af0
add esp, 8
push 0
push esi
call fcn.0041d2ac
add esp, 8
test eax, eax
je 0x40a193
push esi
push edi
call fcn.0041dd1a
add esp, 8
test eax, eax
je 0x40a22a
mov ecx, dword [0x43db8c]
mov edx, dword fs:[0x2c]
mov eax, dword [0x43fa9c]
mov ecx, dword [edx + ecx*4]
cmp eax, dword [ecx + 4]
jg 0x40a2de
call fcn.0041a26c
push dword [eax]
push esi
push edi
push str.rename_file:_failed_to_rename_file___src:__S__dst:_S__err:__d
push 0x43f890
call fcn.00410af0
add esp, 0x14
mov ebx, 7
jmp 0x40a0b8
push 0x180
push esi
call fcn.0041d53f
add esp, 8
push esi
call fcn.0041dcf2
add esp, 4
test eax, eax
je 0x40a13b
mov ecx, dword [0x43db8c]
mov edx, dword fs:[0x2c]
mov ebx, eax
mov eax, dword [0x43fa9c]
mov ecx, dword [edx + ecx*4]
cmp eax, dword [ecx + 4]
jg 0x40a321
call fcn.0041a26c
push dword [eax]
push ebx
push esi
push str.ensure_remove:_failed_to_remove_file:__S__rv:__d__err:__d
push 0x43f890
call fcn.00410af0
add esp, 0x14
mov ecx, dword [0x43db8c]
mov edx, dword fs:[0x2c]
mov eax, dword [0x43fa9c]
mov ecx, dword [edx + ecx*4]
cmp eax, dword [ecx + 4]
jg 0x40a364
push esi
push str.rename_file:_destination_file_exists_and_could_not_be_removed:__S
push 0x43f890
call fcn.00410af0
add esp, 0xc
mov ebx, 0x3e
jmp 0x40a0b8
xor ebx, ebx
jmp 0x40a0b8
push 0x43fa9c
call fcn.004127a7
add esp, 4
cmp dword [0x43fa9c], 0xffffffff
jne 0x40a099
mov dword [0x43f890], 0
push 0x40a010
call fcn.00412a1c
add esp, 4
push 0x43fa9c
call fcn.004127f9
add esp, 4
jmp 0x40a099
push 0x43fa9c
call fcn.004127a7
add esp, 4
cmp dword [0x43fa9c], 0xffffffff
jne 0x40a112
mov dword [0x43f890], 0
push 0x40a010
call fcn.00412a1c
add esp, 4
push 0x43fa9c
call fcn.004127f9
add esp, 4
test bl, bl
jne 0x40a11a
call fcn.0041a26c
push dword [eax]
push edi
push str.rename_file:_path_present__but_not_a_file:__S__err:__d
push 0x43f890
call fcn.00410af0
add esp, 0x10
mov ebx, 0x30
jmp 0x40a0b8
push 0x43fa9c
call fcn.004127a7
add esp, 4
cmp dword [0x43fa9c], 0xffffffff
jne 0x40a16e
mov dword [0x43f890], 0
push 0x40a010
call fcn.00412a1c
add esp, 4
push 0x43fa9c
call fcn.004127f9
add esp, 4
jmp 0x40a16e
push 0x43fa9c
call fcn.004127a7
add esp, 4
cmp dword [0x43fa9c], 0xffffffff
jne 0x40a1d1
mov dword [0x43f890], 0
push 0x40a010
call fcn.00412a1c
add esp, 4
push 0x43fa9c
call fcn.004127f9
add esp, 4
jmp 0x40a1d1
push 0x43fa9c
call fcn.004127a7
add esp, 4
cmp dword [0x43fa9c], 0xffffffff
jne 0x40a20d
mov dword [0x43f890], 0
push 0x40a010
call fcn.00412a1c
add esp, 4
push 0x43fa9c
call fcn.004127f9
add esp, 4
jmp 0x40a20d