Function at 0x40113c
Capabilities:
Copy file
Delete file

Disassembly:
mov eax, 0x415a58
call sub.MSVCRT.dll__EH_prolog
sub esp, 0x81c
push ebx
push esi
mov esi, ecx
xor ebx, ebx
push edi
lea ecx, [ebp - 0x1c]
mov dword [ebp - 0x2c], ebx
mov dword [ebp - 0x24], ebx
call sub.MFC42.DLL_CString::CString_2
lea ecx, [ebp - 0x14]
mov dword [ebp - 4], ebx
call sub.MFC42.DLL_CString::CString_2
lea ecx, [ebp - 0x4c]
mov byte [ebp - 4], 1
call sub.MFC42.DLL_CFile::CFile_1
mov eax, dword [esi + 0xc]
lea edi, [esi + 0xc]
mov byte [ebp - 4], 2
cmp dword [eax - 8], ebx
jne 0x401183
push dword [esi + 0x24]
push str.bgDown_m_szObject_IsEmpty__d
jmp 0x40159e
push 1
lea eax, [ebp - 0x10]
pop ebx
mov ecx, edi
push ebx
push eax
call sub.MFC42.DLL_CString::Mid_1
lea ecx, [esi + 0x28]
push eax
lea eax, [ebp - 0x18]
push ecx
push eax
mov byte [ebp - 4], 3
call sub.MFC42.DLL_operator_2
push eax
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 4
call sub.MFC42.DLL_CString::operator_1
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 3
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x10]
mov byte [ebp - 4], 2
call sub.MFC42.DLL_CString::CString
lea eax, [ebp - 0x18]
push ebx
push eax
mov ecx, edi
call sub.MFC42.DLL_CString::Mid_1
lea ecx, [esi + 0x2c]
push eax
lea eax, [ebp - 0x10]
push ecx
push eax
mov byte [ebp - 4], 5
call sub.MFC42.DLL_operator_2
push eax
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], 6
call sub.MFC42.DLL_CString::operator_1
lea ecx, [ebp - 0x10]
mov byte [ebp - 4], 5
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 2
call sub.MFC42.DLL_CString::CString
push 0x5c
push 0x2f
lea ecx, [ebp - 0x1c]
call sub.MFC42.DLL_CString::Replace_1
push 0x5c
push 0x2f
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::Replace_1
lea eax, [ebp - 0x164]
push eax
push dword [ebp - 0x1c]
call sub.MFC42.DLL_CFile::GetStatus_1
cmp eax, ebx
jne 0x401249
mov eax, dword [ebp - 0x158]
mov dword [ebp - 0x2c], eax
mov eax, dword [ebp - 0x160]
mov dword [ebp - 0x34], eax
lea eax, [ebp - 0x27c]
push eax
push dword [ebp - 0x14]
call sub.MFC42.DLL_CFile::GetStatus_1
cmp eax, ebx
jne 0x40126e
mov eax, dword [ebp - 0x270]
mov dword [ebp - 0x24], eax
mov eax, dword [ebp - 0x278]
mov dword [ebp - 0x38], eax
push 0
push 0x50
push ecx
lea eax, [esi + 8]
mov ecx, esp
mov dword [ebp - 0x10], esp
push eax
call sub.MFC42.DLL_CString::CString_1
mov ecx, esi
call fcn.004097f1
test eax, eax
mov dword [esi + 4], eax
jg 0x40129b
push dword [edi]
push str.bgDown__s_ConnectServer_Err
jmp 0x40139a
mov ecx, dword [esi + 0x24]
test ecx, ecx
jl 0x4012af
mov edx, dword [esi + 0x30]
lea ecx, [ecx + ecx*2]
mov dword [edx + ecx*8 + 0xb9b0], eax
push 0
push str.HEAD
mov ecx, esi
call fcn.00409915
xor ebx, ebx
cmp eax, ebx
jle 0x4015a9
push 0x5aa
lea eax, [ebp - 0x828]
push ebx
push eax
call sub.MSVCRT.dll_memset
add esp, 0xc
lea eax, [ebp - 0x828]
mov ecx, esi
push ebx
push 0x5a9
push eax
push dword [esi + 4]
push ebx
call fcn.00409b17
cmp eax, ebx
jg 0x401304
push dword [edi]
push str.recv_err__s
jmp 0x40159e
lea ecx, [ebp - 0x20]
push ecx
lea ecx, [ebp - 0x30]
push ecx
lea ecx, [ebp - 0x28]
push ecx
lea ecx, [ebp - 0x3c]
push ecx
push eax
lea eax, [ebp - 0x828]
mov ecx, esi
push eax
call fcn.00409b4d
cmp eax, ebx
jg 0x40133f
push eax
push dword [edi]
push str.SplitHead_err__s__d
push 1
push esi
call fcn.00409f0c
add esp, 0x14
jmp 0x4015a9
mov eax, dword [ebp - 0x2c]
cmp eax, dword [esi + 0x14]
jne 0x401367
push ecx
mov ecx, dword [esi + 0x10]
mov eax, esp
mov dword [ebp - 0x10], esp
mov dword [eax], ecx
lea ecx, [ebp - 0x34]
call fcn.00401626
cmp eax, ebx
je 0x401367
push dword [edi]
push str.no_change__s
jmp 0x40139a
mov eax, dword [ebp - 0x24]
cmp eax, dword [esi + 0x14]
jne 0x4013a0
push ecx
mov ecx, dword [esi + 0x10]
mov eax, esp
mov dword [ebp - 0x10], esp
mov dword [eax], ecx
lea ecx, [ebp - 0x38]
call fcn.00401626
cmp eax, ebx
je 0x4013a0
push ebx
push dword [ebp - 0x1c]
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_CopyFileA]
push dword [edi]
push str.no_change2__s
push ebx
jmp 0x4015a0
push ecx
mov ecx, esp
mov dword [ebp - 0x18], esp
push edi
call sub.MFC42.DLL_CString::CString_1
push ecx
lea eax, [esi + 0x2c]
mov ecx, esp
mov dword [ebp - 0x24], esp
push eax
mov byte [ebp - 4], 7
call sub.MFC42.DLL_CString::CString_1
lea eax, [ebp - 0x10]
mov ecx, esi
push eax
mov byte [ebp - 4], 2
call fcn.00409d90
lea ecx, [ebp - 0x10]
call sub.MFC42.DLL_CString::CString
push ecx
mov ecx, esp
mov dword [ebp - 0x18], esp
push edi
call sub.MFC42.DLL_CString::CString_1
push ecx
lea eax, [esi + 0x28]
mov ecx, esp
mov dword [ebp - 0x24], esp
push eax
mov byte [ebp - 4], 8
call sub.MFC42.DLL_CString::CString_1
lea eax, [ebp - 0x10]
mov ecx, esi
push eax
mov byte [ebp - 4], 2
call fcn.00409d90
lea ecx, [ebp - 0x10]
call sub.MFC42.DLL_CString::CString
cmp dword [ebp - 0x28], 1
jne 0x401445
mov ecx, esi
call fcn.00409d79
push ebx
push 0x50
push ecx
lea eax, [esi + 8]
mov ecx, esp
mov dword [ebp - 0x18], esp
push eax
call sub.MFC42.DLL_CString::CString_1
mov ecx, esi
call fcn.004097f1
cmp eax, ebx
mov dword [esi + 4], eax
jg 0x401445
push dword [edi]
push str.bgDown__s_ConnectServer_Err
jmp 0x40159e
push ebx
push 0x41e070
mov ecx, esi
call fcn.00409915
cmp eax, ebx
jg 0x401462
push dword [edi]
push str.get_err__s
jmp 0x40159e
push ebx
lea eax, [ebp - 0x828]
push 0x5a9
push eax
push dword [esi + 4]
mov ecx, esi
push ebx
call fcn.00409b17
cmp eax, ebx
jle 0x4015a9
lea ecx, [ebp - 0x20]
and byte [ebp + eax - 0x828], 0
push ecx
lea ecx, [ebp - 0x30]
push ecx
lea ecx, [ebp - 0x28]
push ecx
lea ecx, [ebp - 0x3c]
push ecx
push eax
lea eax, [ebp - 0x828]
mov ecx, esi
push eax
call fcn.00409b4d
cmp eax, ebx
jle 0x4015a9
mov eax, dword [ebp - 0x20]
push ebx
push 0x9001
lea ecx, [ebp - 0x4c]
push dword [ebp - 0x14]
mov dword [esi + 0x18], eax
call sub.MFC42.DLL_CFile::Open
cmp eax, ebx
je 0x4015a9
cmp dword [ebp - 0x20], ebx
jle 0x4014e3
push dword [ebp - 0x20]
lea ecx, [ebp - 0x4c]
push dword [ebp - 0x30]
call sub.MFC42.DLL_CFile::Write
push dword [ebp - 0x20]
push str.bgdown_write__d
push ebx
push esi
call fcn.00409f0c
add esp, 0x10
jmp 0x4014f9
xor ebx, ebx
push ebx
lea eax, [ebp - 0x828]
push 0x5a9
push eax
push dword [esi + 4]
mov ecx, esi
push ebx
call fcn.00409b17
mov ebx, eax
test ebx, ebx
jle 0x40153a
and byte [ebp + ebx - 0x828], 0
lea eax, [ebp - 0x828]
push ebx
push eax
lea ecx, [ebp - 0x4c]
call sub.MFC42.DLL_CFile::Write
add dword [esi + 0x18], ebx
mov eax, dword [esi + 0x18]
cmp eax, dword [esi + 0x14]
jl 0x4014f7
lea ecx, [ebp - 0x4c]
call sub.MFC42.DLL_CFile::Close
mov eax, dword [esi + 0x18]
cmp eax, dword [esi + 0x14]
jne 0x40158e
lea eax, [ebp - 0x164]
push eax
push dword [ebp - 0x14]
call sub.MFC42.DLL_CFile::GetStatus_1
test eax, eax
je 0x4015a9
mov eax, dword [esi + 0x10]
mov dword [ebp - 0x160], eax
lea eax, [ebp - 0x164]
push eax
push dword [ebp - 0x14]
call sub.MFC42.DLL_CFile::SetStatus
push 0
push dword [ebp - 0x1c]
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_CopyFileA]
push dword [edi]
push str.end_bgdown__s
push 0
jmp 0x4015a0
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
push dword [edi]
push str.Error_end_bgdown__s
push 1
push esi
call fcn.00409f0c
add esp, 0x10
mov ecx, esi
call fcn.00409d79
mov ecx, esi
call fcn.004015ea
lea ecx, [ebp - 0x4c]
mov byte [ebp - 4], 1
call sub.MFC42.DLL_CFile::CFile
and byte [ebp - 4], 0
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::CString
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x1c]
call sub.MFC42.DLL_CString::CString
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
leave
ret