Function at 0x401d10
Capabilities:
Delete file

Disassembly:
sub esp, 0x24
push ebx
push ebp
push esi
mov esi, dword [esp + 0x34]
xor ebx, ebx
push edi
cmp esi, ebx
mov byte [0x412580], bl
mov ebp, 1
jne 0x401d41
cmp dword [0x412588], ebp
je 0x401d41
push str.compress:_bad_modes_n
call fcn.00402850
add esp, 4
mov eax, dword [0x412588]
dec eax
je 0x401d99
dec eax
je 0x401d87
dec eax
jne 0x401dba
push esi
push 0x413200
call fcn.00401ca0
push esi
push 0x4129c0
call fcn.00401ca0
mov edi, 0x4129c0
or ecx, 0xffffffff
xor eax, eax
add esp, 0x10
repne scasb al, byte es:[edi]
mov eax, dword [str..bz2]
mov cl, byte [0x40fd30]
dec edi
mov dword [edi], eax
mov byte [edi + 4], cl
jmp 0x401dba
push esi
push 0x413200
call fcn.00401ca0
push 0x40fd34
jmp 0x401dad
push 0x40fd18
push 0x413200
call fcn.00401ca0
push 0x40fd20
push 0x4129c0
call fcn.00401ca0
add esp, 0x10
cmp dword [0x412588], ebp
je 0x401e6d
push 0x413200
call fcn.00402a80
add esp, 4
test al, al
je 0x401e13
cmp byte [0x4131eb], bl
je 0x401e02
mov edx, dword [0x41360c]
mov eax, dword [sym.imp.MSVCRT.dll__iob]
push 0x413200
push edx
add eax, 0x40
push 0x40fd40
push eax
call dword [sym.imp.MSVCRT.dll_fprintf]
add esp, 0x10
push ebp
call fcn.00401a00
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret
cmp dword [0x412588], ebp
je 0x401e6d
push 0x413200
call fcn.004029a0
add esp, 4
test al, al
jne 0x401e6d
call dword [sym.imp.MSVCRT.dll__errno]
mov ecx, dword [eax]
push ecx
call dword [sym.imp.MSVCRT.dll_strerror]
mov edx, dword [0x41360c]
push eax
mov eax, dword [sym.imp.MSVCRT.dll__iob]
push 0x413200
push edx
add eax, 0x40
push 0x40fd68
push eax
call dword [sym.imp.MSVCRT.dll_fprintf]
push ebp
call fcn.00401a00
add esp, 0x1c
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret
xor edi, edi
mov esi, 0x40f010
mov ecx, dword [esi]
push ecx
push 0x413200
call fcn.00402aa0
add esp, 8
test al, al
jne 0x401ef4
add esi, 4
inc edi
cmp esi, 0x40f020
jl 0x401e74
mov eax, dword [0x412588]
cmp eax, 3
je 0x401ea7
cmp eax, 2
jne 0x401f3d
lea edx, [esp + 0x10]
push edx
push 0x413200
call dword [sym.imp.MSVCRT.dll__stat]
mov eax, dword [esp + 0x1e]
add esp, 8
test ah, 0x40
je 0x401f38
mov eax, dword [0x41360c]
mov ecx, dword [sym.imp.MSVCRT.dll__iob]
push 0x413200
push eax
add ecx, 0x40
push 0x40fdb8
push ecx
call dword [sym.imp.MSVCRT.dll_fprintf]
push ebp
call fcn.00401a00
add esp, 0x14
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret
cmp byte [0x4131eb], bl
je 0x401f27
mov edx, dword [edi*4 + 0x40f010]
mov eax, dword [0x41360c]
mov ecx, dword [sym.imp.MSVCRT.dll__iob]
push edx
push 0x413200
push eax
add ecx, 0x40
push str._s:_Input_file__s_already_has__s_suffix._n
push ecx
call dword [sym.imp.MSVCRT.dll_fprintf]
add esp, 0x14
push ebp
call fcn.00401a00
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret
mov eax, dword [0x412588]
mov ebp, dword [sym.imp.MSVCRT.dll_remove]
cmp eax, 3
jne 0x402075
cmp byte [0x41361c], bl
jne 0x401fb0
push 0x413200
call fcn.004029f0
add esp, 4
test al, al
je 0x401fa2
cmp byte [0x4131eb], bl
je 0x401f90
mov edx, dword [0x41360c]
mov eax, dword [sym.imp.MSVCRT.dll__iob]
push 0x413200
push edx
add eax, 0x40
push 0x40fddc
push eax
call dword [sym.imp.MSVCRT.dll_fprintf]
add esp, 0x10
push 1
call fcn.00401a00
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret
mov eax, dword [0x412588]
cmp eax, 3
jne 0x402075
push 0x4129c0
call fcn.004029a0
add esp, 4
test al, al
je 0x401fd4
mov al, byte [0x41361c]
push 0x4129c0
cmp al, bl
je 0x40202b
call ebp
add esp, 4
mov eax, dword [0x412588]
cmp eax, 3
jne 0x402075
cmp byte [0x41361c], bl
jne 0x402063
push 0x413200
call fcn.00402a20
add esp, 4
cmp eax, ebx
jle 0x402059
cmp eax, 1
mov ecx, 0x40fe2c
jg 0x40200a
mov ecx, 0x41255c
push ecx
mov ecx, dword [sym.imp.MSVCRT.dll__iob]
push eax
mov eax, dword [0x41360c]
push 0x413200
push eax
add ecx, 0x40
push 0x40fe30
push ecx
jmp 0x4022cb
mov ecx, dword [0x41360c]
mov edx, dword [sym.imp.MSVCRT.dll__iob]
push ecx
add edx, 0x40
push 0x40fe08
push edx
call dword [sym.imp.MSVCRT.dll_fprintf]
push 1
call fcn.00401a00
add esp, 0x14
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret
mov eax, dword [0x412588]
cmp eax, 3
jne 0x402075
push 0x413200
call fcn.00402a50
mov eax, dword [0x412588]
add esp, 4
dec eax
je 0x4022e3
dec eax
je 0x402210
dec eax
je 0x402142
push str.compress:_bad_srcMode
call fcn.00402850
mov edi, dword [esp + 0x3c]
mov esi, dword [esp + 0x3c]
add esp, 4
cmp dword [0x413610], 1
jl 0x4020de
mov eax, dword [sym.imp.MSVCRT.dll__iob]
push 0x413200
add eax, 0x40
push 0x40ff9c
push eax
call dword [sym.imp.MSVCRT.dll_fprintf]
push 0x413200
call fcn.00402930
mov ecx, dword [sym.imp.MSVCRT.dll__iob]
add ecx, 0x40
push ecx
call dword [sym.imp.MSVCRT.dll_fflush]
add esp, 0x14
push esi
push edi
mov dword [0x412590], esi
mov byte [0x412580], 1
call fcn.00402350
mov eax, dword [0x412588]
add esp, 8
cmp eax, 3
mov dword [0x412590], ebx
jne 0x402134
push 0x4129c0
call fcn.00402a60
mov al, byte [0x41258d]
add esp, 4
cmp al, bl
mov byte [0x412580], bl
jne 0x402134
push 0x413200
call ebp
add esp, 4
test eax, eax
je 0x402134
call fcn.00402890
pop edi
pop esi
mov byte [0x412580], bl
pop ebp
pop ebx
add esp, 0x24
ret
push 0x40ff30
push 0x413200
call dword [sym.imp.MSVCRT.dll_fopen]
push 0x40ff34
push 0x4129c0
mov edi, eax
call fcn.004029d0
mov esi, eax
add esp, 0x10
cmp esi, ebx
jne 0x4021bf
call dword [sym.imp.MSVCRT.dll__errno]
mov edx, dword [eax]
push edx
call dword [sym.imp.MSVCRT.dll_strerror]
mov ecx, dword [sym.imp.MSVCRT.dll__iob]
push eax
mov eax, dword [0x41360c]
push 0x4129c0
push eax
add ecx, 0x40
push 0x40ff38
push ecx
call dword [sym.imp.MSVCRT.dll_fprintf]
add esp, 0x18
cmp edi, ebx
je 0x4021ad
push edi
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
push 1
call fcn.00401a00
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret
cmp edi, ebx
jne 0x40209f
call dword [sym.imp.MSVCRT.dll__errno]
mov edx, dword [eax]
push edx
call dword [sym.imp.MSVCRT.dll_strerror]
mov ecx, dword [sym.imp.MSVCRT.dll__iob]
push eax
mov eax, dword [0x41360c]
push 0x413200
push eax
add ecx, 0x40
push 0x40ff60
push ecx
call dword [sym.imp.MSVCRT.dll_fprintf]
push esi
call dword [sym.imp.MSVCRT.dll_fclose]
push 1
call fcn.00401a00
add esp, 0x20
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret
push 0x40feb0
push 0x413200
call dword [sym.imp.MSVCRT.dll_fopen]
mov edx, dword [sym.imp.MSVCRT.dll__iob]
mov edi, eax
lea esi, [edx + 0x20]
push esi
call dword [sym.imp.MSVCRT.dll__fileno]
push eax
call dword [sym.imp.MSVCRT.dll__isatty]
add esp, 0x10
test eax, eax
je 0x402298
mov eax, dword [0x41360c]
mov ecx, dword [sym.imp.MSVCRT.dll__iob]
mov esi, dword [sym.imp.MSVCRT.dll_fprintf]
push eax
add ecx, 0x40
push str._s:_I_wont_write_compressed_data_to_a_terminal._n
push ecx
call esi
mov eax, dword [0x41360c]
mov edx, dword [sym.imp.MSVCRT.dll__iob]
push eax
push eax
add edx, 0x40
push 0x40fee8
push edx
call esi
add esp, 0x1c
cmp edi, ebx
je 0x402286
push edi
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
push 1
call fcn.00401a00
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret
cmp edi, ebx
jne 0x40209f
call dword [sym.imp.MSVCRT.dll__errno]
mov eax, dword [eax]
push eax
call dword [sym.imp.MSVCRT.dll_strerror]
mov ecx, dword [0x41360c]
mov edx, dword [sym.imp.MSVCRT.dll__iob]
push eax
push 0x413200
push ecx
add edx, 0x40
push 0x40ff0c
push edx
call dword [sym.imp.MSVCRT.dll_fprintf]
push 1
call fcn.00401a00
add esp, 0x1c
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret
mov edi, dword [sym.imp.MSVCRT.dll__iob]
lea esi, [edi + 0x20]
push esi
call dword [sym.imp.MSVCRT.dll__fileno]
push eax
call dword [sym.imp.MSVCRT.dll__isatty]
add esp, 8
test eax, eax
je 0x40209f
mov eax, dword [0x41360c]
mov ecx, dword [sym.imp.MSVCRT.dll__iob]
mov esi, dword [sym.imp.MSVCRT.dll_fprintf]
push eax
add ecx, 0x40
push 0x40fe58
push ecx
call esi
mov eax, dword [0x41360c]
mov edx, dword [sym.imp.MSVCRT.dll__iob]
push eax
push eax
add edx, 0x40
push 0x40fe8c
push edx
call esi
push 1
call fcn.00401a00
add esp, 0x20
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret