Function at 0x406440
Capabilities:
Delete file

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x4579d8
mov eax, dword fs:[0]
push eax
sub esp, 0x298
mov eax, dword [0x47c9a0]
xor eax, esp
mov dword [esp + 0x290], eax
push ebx
push esi
push edi
mov eax, dword [0x47c9a0]
xor eax, esp
push eax
lea eax, [esp + 0x2a8]
mov dword fs:[0], eax
mov edi, edx
mov dword [esp + 0x14], edi
lea ecx, [esp + 0x20]
call fcn.00405310
mov dword [esp + 0x2b0], 0
mov dword [esp + 0x3c], 0
mov dword [esp + 0x48], 0
mov dword [esp + 0x44], 0
mov dword [esp + 0x40], 0
mov dword [esp + 0x38], vtable.OCArray_class_CKlidRegEntry_.0
mov dword [esp + 0x28], 0
mov dword [esp + 0x34], 0
mov dword [esp + 0x30], 0
mov dword [esp + 0x2c], 0
mov dword [esp + 0x24], vtable.OCArray_class_CKlidRegEntry_.0
push edi
lea edx, [esp + 0x3c]
mov byte [esp + 0x2b4], 2
lea ecx, [esp + 0x24]
call fcn.00405760
add esp, 4
or ebx, 0xffffffff
test al, al
je 0x406574
push edi
lea edx, [esp + 0x28]
lea ecx, [esp + 0x24]
call fcn.004055e0
add esp, 4
test al, al
je 0x406574
cmp dword [esp + 0x40], 0
jle 0x4065f9
lea edx, [esp + 0x38]
lea ecx, [esp + 0x14]
call fcn.00405a10
mov byte [esp + 0x2b0], 3
push dword [eax]
push str.Layout_cannot_be_uninstalled_because_following_layout_s__are_still_loaded_in_the_Language_Bar:_r_n_r_n_s_r_n_r_nPlease_remove_these_layouts_from_the_Language_Bar_first
push edi
call fcn.00403ff0
mov byte [esp + 0x2bc], 2
add esp, 0xc
mov edx, dword [esp + 0x14]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
mov ecx, ebx
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x406574
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [esp + 0x13], 0
mov byte [esp + 0x2b0], 1
lea ecx, [esp + 0x24]
mov dword [esp + 0x24], vtable.OCArray_class_CKlidRegEntry_.0
call fcn.00403a60
mov byte [esp + 0x2b0], 0
lea ecx, [esp + 0x38]
mov dword [esp + 0x38], vtable.OCArray_class_CKlidRegEntry_.0
call fcn.00403a60
mov dword [esp + 0x2b0], 0xffffffff
mov esi, dword [esp + 0x20]
add esi, 0xfffffff0
lea eax, [esi + 0xc]
lock xadd dword [eax], ebx
dec ebx
test ebx, ebx
jg 0x4065d1
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov al, byte [esp + 0x13]
mov ecx, dword [esp + 0x2a8]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x290]
xor ecx, esp
call fcn.0043f01f
mov esp, ebp
pop ebp
ret
mov eax, dword [esp + 0x2c]
xor esi, esi
mov dword [esp + 0x18], eax
test eax, eax
jle 0x406633
xor edi, edi
lea esp, [esp]
mov ebx, dword [esp + 0x28]
add ebx, edi
mov ecx, dword [ebx]
call fcn.00413510
test al, al
je 0x40673c
inc esi
add edi, 0x1c
cmp esi, dword [esp + 0x18]
jl 0x406610
mov edi, dword [esp + 0x14]
push 0
push 0x464d24
mov ecx, edi
mov byte [esp + 0x1b], 1
call fcn.004045b0
lea ecx, [esp + 0x14]
call fcn.00405310
mov esi, eax
lea ecx, [esp + 0x18]
mov byte [esp + 0x2b0], 5
call fcn.0040daa0
mov byte [esp + 0x2b0], 6
lea ecx, [esp + 0x1c]
push dword [esi]
mov edx, dword [eax]
call fcn.0040d6e0
add esp, 4
mov byte [esp + 0x2b0], 8
or ebx, 0xffffffff
mov edx, dword [esp + 0x18]
mov eax, ebx
add edx, 0xfffffff0
lea ecx, [edx + 0xc]
lock xadd dword [ecx], eax
dec eax
test eax, eax
jg 0x4066a2
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [esp + 0x2b0], 9
mov ecx, ebx
mov edx, dword [esp + 0x14]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x4066c7
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
lea eax, [esp + 0x4c]
push eax
push dword [esp + 0x20]
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
cmp eax, 0xffffffff
je 0x40670e
push eax
call dword [sym.imp.KERNEL32.dll_FindClose]
test byte [esp + 0x4c], 0x10
jne 0x40670e
push dword [esp + 0x1c]
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x40670e
push dword [esp + 0x1c]
push str.Couldnt_delete_file__s_r_nMake_sure_you_have_full_write_access_to_the_Windows_System_directory
push edi
call fcn.00403ff0
add esp, 0xc
mov byte [esp + 0x13], 0
mov byte [esp + 0x2b0], 2
mov ecx, ebx
mov edx, dword [esp + 0x1c]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x406579
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
jmp 0x406579
lea eax, [esp + 0x18]
mov ecx, ebx
push eax
call fcn.00411930
mov byte [esp + 0x2b0], 4
push dword [eax]
push str.Couldnt_uninstall_layout__s
push dword [esp + 0x1c]
call fcn.00403ff0
mov byte [esp + 0x2bc], 2
add esp, 0xc
mov edx, dword [esp + 0x18]
add edx, 0xfffffff0
or ebx, 0xffffffff
jmp 0x40655e