Function at 0x40a4b0
Capabilities:
Delete file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4371fb
mov eax, dword fs:[0]
push eax
sub esp, 0x78
push ebx
push esi
push edi
mov eax, dword [0x47700c]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
mov esi, dword [ebp + 8]
test esi, esi
je 0x40a76d
mov edx, 0x4579d0
mov ecx, esi
call fcn.00401f50
push eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
add esp, 4
lea ecx, [ebp - 0x24]
push 1
push 1
push 1
push 0x400
call fcn.00408260
push 1
push 1
push 1
push pe_nt_image_headers32
lea ecx, [ebp - 0x6c]
mov dword [ebp - 4], 0
call fcn.00408260
push 1
push 1
push 1
push pe_nt_image_headers32
lea ecx, [ebp - 0x54]
mov byte [ebp - 4], 1
call fcn.00408260
mov edx, 0x457fc0
mov byte [ebp - 4], 2
mov ecx, esi
call fcn.00401f50
mov ecx, eax
call fcn.004020a0
mov edi, dword [ebp - 0x58]
nop dword [eax]
call fcn.00401d80
push eax
push str._s.hdr
push dword [ebp - 0x6c]
push edi
call fcn.004012c0
add esp, 0x10
mov edx, 0x4579d0
mov ecx, edi
call fcn.00404110
mov esi, eax
test esi, esi
je 0x40a5c7
push 0
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
add esp, 4
cmp esi, eax
je 0x40a5c3
push 1
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
add esp, 4
cmp esi, eax
je 0x40a5c3
push esi
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
add esp, 4
test eax, eax
je 0x40a5c3
push eax
push str.cimg::fclose__:_Error_code__d_returned_during_file_closing.
call fcn.00401b40
add esp, 8
test esi, esi
jne 0x40a560
mov edx, dword [ebp + 8]
mov ecx, edx
lea esi, [ecx + 1]
nop
mov al, byte [ecx]
inc ecx
test al, al
jne 0x40a5d0
push 0
sub esp, 8
sub ecx, esi
push 1
lea eax, [ecx + 1]
push eax
push edx
lea ecx, [ebp - 0x84]
call fcn.00408110
mov byte [ebp - 4], 3
test edi, edi
jne 0x40a60d
mov dword [ebp - 0x3c], edi
mov dword [ebp - 0x38], edi
mov dword [ebp - 0x34], edi
mov dword [ebp - 0x30], edi
mov byte [ebp - 0x2c], 0
mov dword [ebp - 0x28], edi
jmp 0x40a62f
mov ecx, edi
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x40a612
push 0
sub esp, 8
sub ecx, edx
push 1
lea eax, [ecx + 1]
push eax
push edi
lea ecx, [ebp - 0x3c]
call fcn.00408110
lea ecx, [ebp - 0x84]
mov byte [ebp - 4], 4
call fcn.00412450
lea ecx, [ebp - 0x3c]
mov esi, dword [eax + 0x14]
call fcn.00412450
push esi
push dword [eax + 0x14]
call fcn.00405d30
mov edi, dword [ebp - 0x10]
push eax
push str._s__w__c_anlz__o___s___f___s_
push dword [ebp - 0x24]
push edi
call fcn.004012c0
add esp, 0x18
cmp byte [ebp - 0x2c], 0
jne 0x40a678
push dword [ebp - 0x28]
call fcn.0043575c
add esp, 4
mov byte [ebp - 4], 2
cmp byte [ebp - 0x74], 0
jne 0x40a68d
push dword [ebp - 0x70]
call fcn.0043575c
add esp, 4
xor edx, edx
mov ecx, edi
call fcn.00401be0
mov esi, dword [ebp - 0x40]
mov edx, esi
mov ecx, dword [ebp - 0x58]
call fcn.00402100
push esi
push str._s.hdr
push dword [ebp - 0x24]
push edi
call fcn.004012c0
add esp, 0x10
mov edx, 0x4579d0
mov ecx, edi
call fcn.00404110
test eax, eax
jne 0x40a6eb
push esi
push str.m000__s.hdr
push dword [ebp - 0x24]
push edi
call fcn.004012c0
add esp, 0x10
mov edx, 0x4579d0
mov ecx, edi
call fcn.00404110
test eax, eax
je 0x40a7b2
mov ecx, eax
call fcn.004020a0
push ecx
push edi
push ecx
mov ecx, ebx
call fcn.0040f8b0
mov esi, dword [sym.imp.api_ms_win_crt_filesystem_l1_1_0.dll_remove]
push edi
call esi
mov edx, dword [ebp - 0x40]
mov ecx, edi
call fcn.00402100
push dword [ebp - 0x40]
push str._s.img
push dword [ebp - 0x24]
push edi
call fcn.004012c0
push edi
call esi
add esp, 0x18
cmp byte [ebp - 0x44], 0
jne 0x40a737
push dword [ebp - 0x40]
call fcn.0043575c
add esp, 4
cmp byte [ebp - 0x5c], 0
jne 0x40a748
push dword [ebp - 0x58]
call fcn.0043575c
add esp, 4
cmp byte [ebp - 0x14], 0
jne 0x40a757
push edi
call fcn.0043575c
add esp, 4
mov eax, ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
call fcn.00401920
cmp byte [ebx + 0x10], 0
mov ecx, str.non_
push eax
mov eax, 0x4393e2
cmove eax, ecx
push eax
push dword [ebx + 0x14]
lea eax, [ebp - 0x1c]
push dword [ebx + 0xc]
push dword [ebx + 8]
push dword [ebx + 4]
push dword [ebx]
push str._instance__u__u__u__u__p__sshared___CImg__s_::load_medcon_external__:_Specified_filename_is__null_.
push eax
call fcn.00401450
add esp, 0x24
lea eax, [ebp - 0x1c]
push 0x475714
push eax
call sub.VCRUNTIME140.dll__CxxThrowException
push dword [ebp + 8]
call fcn.00401920
cmp byte [ebx + 0x10], 0
mov ecx, str.non_
push eax
mov eax, 0x4393e2
cmove eax, ecx
push eax
push dword [ebx + 0x14]
lea eax, [ebp - 0x34]
push dword [ebx + 0xc]
push dword [ebx + 8]
push dword [ebx + 4]
push dword [ebx]
push str._instance__u__u__u__u__p__sshared___CImg__s_::load_medcon_external__:_Failed_to_load_file__s_with_external_command_medcon.
push eax
call fcn.00401780
add esp, 0x28
lea eax, [ebp - 0x34]
push 0x47569c
push eax
call sub.VCRUNTIME140.dll__CxxThrowException
int3