Function at 0x4036e0
Capabilities:
Delete file
Get common file path
Move file

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
mov ebx, edx
sub esp, 0x244
mov dword [ebp - 0x238], eax
test byte [section..data], 8
jne 0x403be0
mov dword [esp + 8], 0
xor esi, esi
lea eax, [ebp - 0x214]
mov dword [esp + 4], 0x40e438
mov dword [esp + 0xc], eax
mov eax, dword [0x41a20c]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_GetTempFileNameW]
lea eax, [ebp - 0x214]
sub esp, 0x10
mov dword [esp], eax
mov eax, dword [sym.imp.ucrtbase.dll__wfopen]
mov dword [esp + 4], 0x40e262
mov dword [ebp - 0x234], eax
call eax
mov edi, eax
test eax, eax
je 0x403969
mov dword [esp + 4], str.__DOCTYPE_Menu_PUBLIC_____freedesktop__DTD_Menu_1.0__EN__n
mov dword [esp], eax
call fcn.004011e0
mov dword [esp + 4], str._http:__www.freedesktop.org_standards_menu_spec_menu_1.0.dtd___n
mov dword [esp], edi
call fcn.004011e0
mov dword [esp + 4], str._Menu__n
mov dword [esp], edi
call fcn.004011e0
mov dword [esp + 4], str.___Name_Applications__Name__n
mov dword [esp], edi
call fcn.004011e0
mov dword [esp + 4], ebx
mov dword [esp], str.wine_s.desktop
call fcn.00401950
movzx ecx, word [eax]
mov dword [ebp - 0x218], eax
test cx, cx
je 0x403dc0
lea esi, [eax + 2]
mov dword [ebp - 0x224], eax
mov eax, dword [sym.imp.ucrtbase.dll_fclose]
mov dword [ebp - 0x21c], 0
mov dword [ebp - 0x22c], eax
mov eax, dword [sym.imp.ucrtbase.dll_free]
mov dword [ebp - 0x220], eax
mov eax, esi
cmp cx, 0x5c
je 0x403978
movzx ecx, word [eax]
lea esi, [eax + 2]
test cx, cx
jne 0x4037e1
xor ebx, ebx
mov word [eax], bx
mov dword [esp + 4], str._____Include__n
mov dword [esp], edi
call fcn.004011e0
mov eax, dword [ebp - 0x218]
call fcn.00402390
mov dword [esp + 4], str._______Filename__s__Filename__n
mov dword [esp + 8], eax
mov dword [esp], edi
call fcn.004011e0
mov dword [esp + 4], str.______Include__n
mov dword [esp], edi
call fcn.004011e0
mov esi, dword [ebp - 0x21c]
test esi, esi
je 0x403867
mov esi, dword [ebp - 0x21c]
xor ebx, ebx
nop
mov dword [esp + 4], str.____Menu__n
add ebx, 1
mov dword [esp], edi
call fcn.004011e0
cmp ebx, esi
jne 0x403850
mov dword [esp + 4], str.__Menu__n
mov dword [esp], edi
call fcn.004011e0
mov eax, dword [ebp - 0x218]
mov dword [esp + 8], eax
mov eax, dword [0x41a20c]
mov dword [esp], str._s_s
mov dword [esp + 4], eax
call fcn.00401950
cmp word [eax], 0
mov ebx, eax
je 0x403e20
lea esi, cs:[esi]
lea esi, [esi]
add eax, 2
cmp word [eax], 0
jne 0x4038b0
sub eax, ebx
sar eax, 1
mov edx, str..desktop
lea esi, cs:[esi]
lea esi, [esi]
add edx, 2
cmp word [edx], 0
jne 0x4038d0
sub edx, str..desktop
sar edx, 1
sub eax, edx
lea ecx, [ebx + eax*2]
xor eax, eax
jmp 0x403900
movzx edx, word [eax + str..menu]
mov word [ecx + eax], dx
add eax, 2
test dx, dx
jne 0x403900
mov dword [esp], edi
mov eax, dword [ebp - 0x22c]
call eax
lea eax, [ebp - 0x214]
mov dword [esp + 8], 1
mov dword [esp + 4], ebx
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_MoveFileExW]
sub esp, 0xc
mov esi, eax
test eax, eax
je 0x403bc8
mov edx, dword [ebp - 0x238]
mov eax, ebx
call fcn.00401890
mov eax, dword [ebp - 0x218]
mov dword [esp], eax
mov edi, dword [ebp - 0x220]
call edi
mov dword [esp], ebx
call edi
lea esp, [ebp - 0xc]
mov eax, esi
pop ebx
pop esi
pop edi
pop ebp
ret
mov ecx, dword [ebp - 0x21c]
test ecx, ecx
jne 0x403e31
xor edx, edx
mov word [esi - 2], dx
mov dword [esp + 4], str.___Menu__n
mov dword [esp], edi
call fcn.004011e0
mov ebx, dword [ebp - 0x218]
mov eax, ebx
call fcn.00402390
mov dword [esp + 8], str.wine_
mov dword [esp + 0xc], eax
mov dword [esp + 4], str._____Name__s_s__Name__n
mov dword [esp], edi
call fcn.004011e0
mov eax, ebx
call fcn.00402390
mov dword [esp + 8], str.wine_
mov dword [esp + 0xc], eax
mov dword [esp + 4], str._____Directory__s_s.directory__Directory__n
mov dword [esp], edi
call fcn.004011e0
mov ecx, dword [sym.imp.kernel32.dll_GetFileAttributesW]
mov eax, 0x40e414
mov dword [ebp - 0x228], ecx
mov ecx, dword [ebp - 0x218]
mov dword [esp + 8], eax
mov dword [esp + 0xc], ecx
mov eax, dword [0x41a208]
mov dword [esp], str._sdesktop_directories_s_s.directory
mov dword [esp + 4], eax
call fcn.00401950
mov dword [esp], eax
mov ebx, eax
mov eax, dword [ebp - 0x228]
call eax
sub esp, 4
cmp eax, 0xffffffff
je 0x403b00
mov dword [esp], ebx
lea ebx, [esi + 2]
mov eax, dword [ebp - 0x220]
call eax
mov edx, 0x2d
mov dword [ebp - 0x224], esi
add dword [ebp - 0x21c], 1
mov word [esi - 2], dx
movzx eax, word [ebx - 2]
test ax, ax
je 0x403c50
cmp ax, 0x5c
je 0x403a88
movzx edx, word [esi + 2]
lea eax, [esi + 4]
test dx, dx
je 0x403cf0
cmp dx, 0x5c
jne 0x4037ed
mov ebx, eax
xor ecx, ecx
mov word [ebx - 2], cx
mov dword [esp + 4], str.___Menu__n
mov dword [esp], edi
call fcn.004011e0
mov esi, dword [ebp - 0x218]
mov eax, esi
call fcn.00402390
mov dword [esp + 8], 0x40e60e
mov dword [esp + 0xc], eax
mov dword [esp + 4], str._____Name__s_s__Name__n
mov dword [esp], edi
call fcn.004011e0
mov eax, esi
mov esi, ebx
call fcn.00402390
mov dword [esp + 8], 0x40e60e
mov dword [esp + 0xc], eax
mov dword [esp + 4], str._____Directory__s_s.directory__Directory__n
mov dword [esp], edi
call fcn.004011e0
mov eax, 0x40e412
jmp 0x4039f9
test byte [section..data], 8
jne 0x403d00
mov dword [esp + 4], 0x40e262
mov dword [esp], ebx
mov eax, dword [ebp - 0x234]
call eax
test eax, eax
je 0x403a35
mov dword [esp + 4], str._Desktop_Entry__n
mov dword [ebp - 0x230], eax
mov dword [esp], eax
call fcn.004011e0
mov dword [esp + 4], str.TypeDirectory_n
mov eax, dword [ebp - 0x230]
mov dword [esp], eax
call fcn.004011e0
mov dword [esp + 4], str.wine
mov ecx, dword [ebp - 0x224]
mov dword [esp], ecx
call dword [sym.imp.ucrtbase.dll_wcscmp]
test eax, eax
je 0x403ca0
mov eax, dword [ebp - 0x224]
call fcn.00401d40
mov dword [esp + 4], str.Name_s_n
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x230]
mov dword [esp], eax
call fcn.004011e0
mov dword [esp + 4], str.Iconfolder_n
mov eax, dword [ebp - 0x230]
mov dword [esp], eax
call fcn.004011e0
mov eax, dword [ebp - 0x230]
mov dword [esp], eax
mov eax, dword [ebp - 0x22c]
call eax
jmp 0x403a35
lea eax, [ebp - 0x214]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_DeleteFileW]
sub esp, 4
jmp 0x403953
test edx, edx
je 0x403e27
mov eax, edx
shr eax, 0x10
test eax, eax
je 0x403cd8
mov dword [esp], edx
mov dword [esp + 4], 0xffffffff
call dword [sym.imp.kernel32.dll_IsBadStringPtrW]
mov edx, eax
sub esp, 8
mov eax, str._invalid_
test edx, edx
jne 0x403c1b
mov eax, ebx
call fcn.00401280
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.__s__n
mov dword [esp + 8], str.write_menu_file
mov dword [esp + 4], 0x40c000
mov dword [esp], 3
call fcn.00401550
jmp 0x403701
xor eax, eax
mov word [esi], ax
mov dword [esp + 4], str._____Include__n
mov dword [esp], edi
call fcn.004011e0
mov eax, dword [ebp - 0x218]
call fcn.00402390
mov dword [esp + 4], str._______Filename__s__Filename__n
mov dword [esp + 8], eax
mov dword [esp], edi
call fcn.004011e0
mov dword [esp + 4], str.______Include__n
mov dword [esp], edi
call fcn.004011e0
jmp 0x403846
mov dword [esp + 4], str.NameWine_n
mov eax, dword [ebp - 0x230]
mov dword [esp], eax
call fcn.004011e0
mov dword [esp + 4], str.Iconwine_n
mov eax, dword [ebp - 0x230]
mov dword [esp], eax
call fcn.004011e0
jmp 0x403bae
mov dword [esp + 4], edx
mov dword [esp], str._04x
call fcn.00401440
jmp 0x403c1b
mov eax, ebx
jmp 0x4037f8
mov eax, ebx
shr eax, 0x10
test eax, eax
je 0x403e43
mov dword [esp + 4], 0xffffffff
mov dword [esp], ebx
call dword [sym.imp.kernel32.dll_IsBadStringPtrW]
sub esp, 8
mov dword [ebp - 0x230], str._invalid_
test eax, eax
jne 0x403d3c
mov eax, ebx
call fcn.00401280
mov dword [ebp - 0x230], eax
mov eax, dword [ebp - 0x224]
test eax, eax
je 0x403e79
shr eax, 0x10
test eax, eax
je 0x403e5e
mov dword [esp + 4], 0xffffffff
mov eax, dword [ebp - 0x224]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_IsBadStringPtrW]
mov edx, eax
sub esp, 8
mov eax, str._invalid_
test edx, edx
jne 0x403d85
mov eax, dword [ebp - 0x224]
call fcn.00401280
mov ecx, dword [ebp - 0x230]
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.__s__s__n
mov dword [esp + 8], str.write_directory_entry
mov dword [esp + 4], 0x40c000
mov dword [esp + 0x14], ecx
mov dword [esp], 3
call fcn.00401550
jmp 0x403b0d
mov dword [esp + 4], str._____Include__n
mov dword [esp], edi
call fcn.004011e0
mov eax, dword [ebp - 0x218]
call fcn.00402390
mov dword [esp + 4], str._______Filename__s__Filename__n
mov dword [esp + 8], eax
mov dword [esp], edi
call fcn.004011e0
mov dword [esp + 4], str.______Include__n
mov dword [esp], edi
call fcn.004011e0
mov eax, dword [sym.imp.ucrtbase.dll_fclose]
mov dword [ebp - 0x22c], eax
mov eax, dword [sym.imp.ucrtbase.dll_free]
mov dword [ebp - 0x220], eax
jmp 0x403867
xor eax, eax
jmp 0x4038bd
mov eax, str._null_
jmp 0x403c1b
mov eax, dword [sym.imp.kernel32.dll_GetFileAttributesW]
mov ebx, esi
mov dword [ebp - 0x228], eax
jmp 0x403a88
mov dword [esp + 4], ebx
mov dword [esp], str._04x
call fcn.00401440
mov dword [ebp - 0x230], eax
jmp 0x403d3c
mov eax, dword [ebp - 0x224]
mov dword [esp], str._04x
mov dword [esp + 4], eax
call fcn.00401440
jmp 0x403d85
mov eax, str._null_
jmp 0x403d85