Function at 0x4994a0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x104c
call fcn.004b0790
push esi
push edi
xor edi, edi
mov esi, ecx
mov dword [ebp - 8], esi
mov dword [ebp - 0x24], edi
mov dword [ebp - 0xc], edi
mov dword [ebp - 0x18], edi
mov dword [ebp - 0x10], edi
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
push eax
lea eax, [ebp - 0x4c]
push 0x4c09b0
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
lea ecx, [ebp - 0x2c]
push 0x4c3290
push ecx
call fcn.00454e20
mov eax, dword [esi + 0x34]
mov ecx, dword [eax + 0x2c]
add esp, 0x14
lea edx, [ebp - 0xc]
push edx
push str.ConEmuUpdate.cmd
push ecx
mov ecx, esi
call fcn.00498dc0
mov dword [ebp - 0x1c], eax
cmp eax, edi
je 0x499ecb
mov edi, dword [sym.imp.KERNEL32.dll_lstrlenA]
push ebx
push str._echo_off_r_n
call edi
mov ebx, dword [sym.imp.KERNEL32.dll_WriteFile]
push 0
lea edx, [ebp - 4]
push edx
mov esi, eax
mov eax, dword [ebp - 0xc]
push esi
push str._echo_off_r_n
push eax
call ebx
test eax, eax
je 0x499e77
cmp esi, dword [ebp - 4]
jne 0x499e77
push 0
push 0
push 0x1000
lea ecx, [ebp - 0x104c]
push ecx
push 0xffffffffffffffff
push str._r_nset_ConEmuInUpdateYES_r_n
push 0
push 1
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
test eax, eax
jne 0x499587
push str._r_nset_ConEmuInUpdateYES_r_n
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov ecx, dword [ebp - 8]
push eax
push str.WideCharToMultiByte_failed__len_i
call fcn.004980a0
jmp 0x499eb7
lea edx, [ebp - 0x104c]
push edx
call edi
mov edx, dword [ebp - 0xc]
push 0
mov esi, eax
lea eax, [ebp - 4]
push eax
push esi
lea ecx, [ebp - 0x104c]
push ecx
push edx
call ebx
test eax, eax
je 0x499e77
cmp esi, dword [ebp - 4]
jne 0x499e77
push str.cd__d__
call edi
mov ecx, dword [ebp - 0xc]
push 0
mov esi, eax
lea eax, [ebp - 4]
push eax
push esi
push str.cd__d__
push ecx
call ebx
test eax, eax
je 0x499e77
cmp esi, dword [ebp - 4]
jne 0x499e77
mov eax, dword [0x50b39c]
push 0
push 0
push 0x1000
lea edx, [ebp - 0x104c]
push edx
push 0xffffffffffffffff
add eax, 0x3be
push eax
push 0
push 1
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
test eax, eax
jne 0x499634
mov ecx, dword [0x50b39c]
add ecx, 0x3be
push ecx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov ecx, dword [ebp - 8]
push eax
push str.WideCharToMultiByte_failed__len_i
call fcn.004980a0
jmp 0x499eb7
lea edx, [ebp - 0x104c]
push edx
call edi
mov edx, dword [ebp - 0xc]
push 0
mov esi, eax
lea eax, [ebp - 4]
push eax
push esi
lea ecx, [ebp - 0x104c]
push ecx
push edx
call ebx
test eax, eax
je 0x499e77
cmp esi, dword [ebp - 4]
jne 0x499e77
push str.__r_necho_Current_folder_r_ncd_r_necho_._r_n_r_necho_Starting_update..._r_n
call edi
mov ecx, dword [ebp - 0xc]
push 0
mov esi, eax
lea eax, [ebp - 4]
push eax
push esi
push str.__r_necho_Current_folder_r_ncd_r_necho_._r_n_r_necho_Starting_update..._r_n
push ecx
call ebx
test eax, eax
je 0x499e77
cmp esi, dword [ebp - 4]
jne 0x499e77
mov esi, dword [ebp - 8]
mov ecx, dword [esi + 0x34]
call fcn.0049c330
mov ecx, dword [esi + 0x34]
cmp al, 1
jne 0x4996a9
call fcn.0049c1f0
jmp 0x4996ae
call fcn.0049c210
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x14], 0
cmp dword [ebp - 0x14], 0
je 0x4996d9
mov eax, dword [ebp - 0x10]
test eax, eax
je 0x49998e
lea edx, [eax + eax + 2]
push edx
call fcn.004412a0
add esp, 4
mov dword [ebp - 0x18], eax
mov ebx, dword [ebp - 0x20]
cmp word [ebx], 0
mov edi, dword [ebp - 0x18]
je 0x4997a7
lea esp, [esp]
movzx eax, word [ebx]
cmp ax, 0x25
je 0x499712
cmp dword [ebp - 0x14], 0
je 0x49970a
mov word [edi], ax
add edi, 2
jmp 0x49979a
inc dword [ebp - 0x10]
jmp 0x49979a
movzx eax, word [ebx + 2]
add ebx, 2
add eax, 0xffffffdb
cmp eax, 0xf
ja case.0x499728.38
movzx eax, byte [eax + 0x499f04]
jmp dword [eax*4 + 0x499eec]
mov edx, 0x4de83c
jmp 0x49973d
mov edx, dword [ebp + 8]
test edx, edx
je 0x49979a
mov eax, edx
lea esi, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x499742
sub eax, esi
sar eax, 1
cmp dword [ebp - 0x14], 0
mov esi, eax
je 0x499797
push edx
lea edx, [esi + 1]
push edx
push edi
call fcn.00401800
lea edi, [edi + esi*2]
jmp 0x49979a
mov edx, dword [0x50b39c]
add edx, 0x3be
jmp 0x499739
lea edx, [ebp - 0x2c]
jmp 0x49973d
lea edx, [ebp - 0x4c]
jmp 0x49973d
sub ebx, 2
cmp dword [ebp - 0x14], 0
je 0x49970a
mov ecx, 0x25
mov word [edi], cx
add edi, 2
jmp 0x49979a
add dword [ebp - 0x10], esi
add ebx, 2
cmp word [ebx], 0
jne 0x4996f0
mov eax, dword [ebp - 0x14]
test eax, eax
je 0x4997b3
xor ecx, ecx
mov word [edi], cx
inc eax
cmp eax, 2
mov dword [ebp - 0x14], eax
jl 0x4996b8
push str.echo
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov ebx, dword [ebp - 0xc]
mov edi, dword [sym.imp.KERNEL32.dll_WriteFile]
push 0
mov esi, eax
lea eax, [ebp - 4]
push eax
push esi
push str.echo
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
mov esi, dword [ebp - 0x18]
push 0
push 0
push 0x1000
lea ecx, [ebp - 0x104c]
push ecx
push 0xffffffffffffffff
push esi
push 0
push 1
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
test eax, eax
je 0x499de9
lea edx, [ebp - 0x104c]
push edx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
mov esi, eax
lea eax, [ebp - 4]
push eax
push esi
lea ecx, [ebp - 0x104c]
push ecx
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
push str._r_ncall
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
lea edx, [ebp - 4]
push edx
mov esi, eax
push esi
push str._r_ncall
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
mov esi, dword [ebp - 0x18]
push 0
push 0
push 0x1000
lea eax, [ebp - 0x104c]
push eax
push 0xffffffffffffffff
push esi
push 0
push 1
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
test eax, eax
je 0x499de9
lea ecx, [ebp - 0x104c]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
lea edx, [ebp - 4]
push edx
mov esi, eax
push esi
lea eax, [ebp - 0x104c]
push eax
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
push str._r_nif_errorlevel_1_goto_err_r_n
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
lea ecx, [ebp - 4]
push ecx
mov esi, eax
push esi
push str._r_nif_errorlevel_1_goto_err_r_n
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
mov edx, dword [ebp - 8]
mov eax, dword [edx + 0x34]
mov eax, dword [eax + 0x28]
test eax, eax
je 0x499a1d
cmp word [eax], 0
je 0x499a1d
push 0x4dd6fc
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
lea ecx, [ebp - 4]
push ecx
mov esi, eax
push esi
push 0x4dd6fc
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
mov esi, dword [ebp - 8]
mov eax, dword [esi + 0x34]
mov ecx, dword [eax + 0x28]
push 0
push 0
push 0x1000
lea edx, [ebp - 0x104c]
push edx
push 0xffffffffffffffff
push ecx
push 0
push 1
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
test eax, eax
jne 0x4999bf
mov edx, dword [esi + 0x34]
mov eax, dword [edx + 0x28]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push eax
push str.WideCharToMultiByte_failed__len_i
mov ecx, esi
jmp 0x499e9c
mov esi, dword [ebp - 8]
mov ecx, dword [esi + 0x34]
call fcn.0049c330
cmp al, 1
mov eax, 0x4db800
je 0x4999a7
mov eax, 0x4e2b74
mov edx, dword [ebp - 0x20]
push 0
push edx
push eax
push str.Invalid__s_update_command___s_
mov ecx, esi
call fcn.00498180
jmp 0x499ea1
lea ecx, [ebp - 0x104c]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
lea edx, [ebp - 4]
push edx
mov esi, eax
push esi
lea eax, [ebp - 0x104c]
push eax
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
push 0x4dd6fc
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
lea ecx, [ebp - 4]
push ecx
mov esi, eax
push esi
push 0x4dd6fc
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
push 0
push 0
push 0x1000
lea edx, [ebp - 0x104c]
push edx
push 0xffffffffffffffff
push str._r_nset_ConEmuInUpdate_r_n
push 0
push 1
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
test eax, eax
jne 0x499a58
push str._r_nset_ConEmuInUpdate_r_n
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push eax
push str.WideCharToMultiByte_failed__len_i
jmp 0x499e99
lea eax, [ebp - 0x104c]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
lea ecx, [ebp - 4]
push ecx
mov esi, eax
push esi
lea edx, [ebp - 0x104c]
push edx
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
push str._r_necho_Starting_ConEmu..._r_nstart__ConEmu___
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
mov esi, eax
lea eax, [ebp - 4]
push eax
push esi
push str._r_necho_Starting_ConEmu..._r_nstart__ConEmu___
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
mov edx, dword [0x50b39c]
push 0
push 0
push 0x1000
lea ecx, [ebp - 0x104c]
push ecx
push 0xffffffffffffffff
add edx, 0x1b4
push edx
push 0
push 1
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
test eax, eax
je 0x499bac
lea ecx, [ebp - 0x104c]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
lea edx, [ebp - 4]
push edx
mov esi, eax
push esi
lea eax, [ebp - 0x104c]
push eax
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
push 0x4e2ad4
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
lea ecx, [ebp - 4]
push ecx
mov esi, eax
push esi
push 0x4e2ad4
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
mov edx, dword [ebp - 8]
cmp byte [edx + 0x68], 0
je 0x499c26
push str._demote__cmd__
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
mov esi, eax
lea eax, [ebp - 4]
push eax
push esi
push str._demote__cmd__
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
mov edx, dword [0x50b39c]
push 0
push 0
push 0x1000
lea ecx, [ebp - 0x104c]
push ecx
push 0xffffffffffffffff
add edx, 0x1b4
push edx
push 0
push 1
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
test eax, eax
jne 0x499bc8
mov eax, dword [0x50b39c]
add eax, 0x1b4
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push eax
push str.WideCharToMultiByte_failed__len_i
jmp 0x499e99
lea ecx, [ebp - 0x104c]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
lea edx, [ebp - 4]
push edx
mov esi, eax
push esi
lea eax, [ebp - 0x104c]
push eax
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
push 0x4e2ad4
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
lea ecx, [ebp - 4]
push ecx
mov esi, eax
push esi
push 0x4e2ad4
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
mov eax, dword [0x50b39c]
cmp dword [eax + 0x208c], 0
je 0x499caa
mov eax, dword [eax + 0x208c]
push 0
push 0
push 0x1000
lea edx, [ebp - 0x104c]
push edx
push 0xffffffffffffffff
push eax
push 0
push 1
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
test eax, eax
jne 0x499c79
mov ecx, dword [0x50b39c]
mov edx, dword [ecx + 0x208c]
push edx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push eax
push str.WideCharToMultiByte_failed__len_i
jmp 0x499e99
lea eax, [ebp - 0x104c]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
lea ecx, [ebp - 4]
push ecx
mov esi, eax
push esi
lea edx, [ebp - 0x104c]
push edx
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
push str._r_ngoto_fin_r_n
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
mov esi, eax
lea eax, [ebp - 4]
push eax
push esi
push str._r_ngoto_fin_r_n
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
push str._r_n:err_r_n
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
lea ecx, [ebp - 4]
push ecx
mov esi, eax
push esi
push str._r_n:err_r_n
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
mov edx, dword [ebp - 8]
mov ecx, dword [edx + 0x34]
call fcn.0049c330
cmp al, 1
mov eax, str.echo__aInstallation_failed_a
je 0x499d1d
mov eax, str.echo__aExtraction_failed_a_r_n
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov esi, eax
mov eax, dword [ebp - 8]
mov ecx, dword [eax + 0x34]
call fcn.0049c330
cmp al, 1
mov eax, str.echo__aInstallation_failed_a
je 0x499d3f
mov eax, str.echo__aExtraction_failed_a_r_n
push 0
lea ecx, [ebp - 4]
push ecx
push esi
push eax
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
push str._r_npause_r_n:fin_r_n
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
lea edx, [ebp - 4]
push edx
mov esi, eax
push esi
push str._r_npause_r_n:fin_r_n
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
mov eax, dword [ebp - 8]
mov ecx, dword [eax + 0x34]
cmp byte [ecx + 0x30], 0
jne 0x499e49
push str.del__
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
lea edx, [ebp - 4]
push edx
mov esi, eax
push esi
push str.del__
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
mov esi, dword [ebp + 8]
push 0
push 0
push 0x1000
lea eax, [ebp - 0x104c]
push eax
push 0xffffffffffffffff
push esi
push 0
push 1
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
test eax, eax
jne 0x499dfb
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push eax
push str.WideCharToMultiByte_failed__len_i
jmp 0x499e99
lea ecx, [ebp - 0x104c]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
lea edx, [ebp - 4]
push edx
mov esi, eax
push esi
lea eax, [ebp - 0x104c]
push eax
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
push 0x4e2a54
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
lea ecx, [ebp - 4]
push ecx
mov esi, eax
push esi
push 0x4e2a54
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
push str.del___0___exit_r_n
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 0
lea edx, [ebp - 4]
push edx
mov esi, eax
push esi
push str.del___0___exit_r_n
push ebx
call edi
test eax, eax
je 0x499e8d
cmp esi, dword [ebp - 4]
jne 0x499e8d
mov dword [ebp - 0x24], 1
jmp 0x499ea1
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [ebp - 8]
push eax
push str.WriteBatch_failed__code_u
call fcn.004980a0
jmp 0x499eb7
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.WriteBatch_failed__code_u
mov ecx, dword [ebp - 8]
call fcn.004980a0
mov eax, dword [ebp - 0x18]
test eax, eax
je 0x499eb1
push eax
call fcn.00441300
add esp, 4
cmp dword [ebp - 0x24], 0
jne 0x499eca
mov eax, dword [ebp - 0x1c]
push eax
call fcn.00441300
add esp, 4
mov dword [ebp - 0x1c], 0
pop ebx
mov eax, dword [ebp - 0xc]
pop edi
pop esi
test eax, eax
je 0x499ee0
cmp eax, 0xffffffff
je 0x499ee0
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x1c]
mov esp, ebp
pop ebp
ret 4