Function at 0x409d62
Capabilities:
Print debug messages
Set current directory

Disassembly:
mov eax, 0x41dc26
call fcn.0041abb0
sub esp, 0x7c
mov eax, dword [0x42b530]
push ebx
push esi
mov esi, dword [sym.imp.MSVCR71.dll__wcsicmp]
push edi
mov edi, dword [ebp + 0x10]
xor eax, ebp
push str._StartTP
push edi
mov dword [ebp - 0x10], eax
xor bl, bl
call esi
test eax, eax
pop ecx
pop ecx
je 0x409db5
push str._debug
push edi
call dword [sym.imp.MSVCR71.dll_wcscmp]
test eax, eax
pop ecx
pop ecx
je 0x409db5
push 0x4212e0
push edi
call esi
test eax, eax
pop ecx
pop ecx
jne 0x409db7
mov bl, 1
lea ecx, [ebp - 0x80]
call fcn.00409518
and dword [ebp - 4], 0
lea eax, [ebp - 0x80]
push eax
call fcn.00409a53
test bl, bl
pop ecx
je 0x409ddb
lea eax, [ebp - 0x80]
push eax
call fcn.004095a3
pop ecx
lea eax, [ebp - 0x80]
push eax
call fcn.0040977b
lea eax, [ebp - 0x2c]
push eax
call fcn.0040e385
pop ecx
pop ecx
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x2c]
call dword [sym.imp.MSVCP71.dll_public:_wchar_t_const____thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::c_str_void_const]
push eax
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
mov ebx, dword [sym.imp.KERNEL32.dll_SetErrorMode]
push 0
call ebx
or eax, 1
push eax
call ebx
push str._RegServer
push edi
call esi
test eax, eax
pop ecx
pop ecx
jne 0x409e3d
call fcn.00409ba3
mov ecx, dword [0x42b6bc]
call fcn.0040906e
mov esi, eax
call fcn.00409c22
jmp 0x409f79
push str._RegServerEx
push edi
call esi
test eax, eax
pop ecx
pop ecx
jne 0x409e5e
call fcn.00409ba3
mov eax, dword [0x42b6bc]
mov byte [eax + 0xf0], 0
jmp 0x409e26
push str._UnRegServer
push edi
call esi
test eax, eax
pop ecx
pop ecx
jne 0x409e7e
call fcn.00409ba3
mov ecx, dword [0x42b6bc]
call fcn.00408cd7
jmp 0x409e31
mov ebx, str._CopyTo
push ebx
call dword [sym.imp.MSVCR71.dll_wcslen]
push eax
push ebx
push edi
call dword [sym.imp.MSVCR71.dll__wcsnicmp]
add esp, 0x10
test eax, eax
jne 0x409ec4
call fcn.00409c84
mov esi, dword [0x42b6c4]
push ebx
call dword [sym.imp.MSVCR71.dll_wcslen]
pop ecx
lea eax, [edi + eax*2]
push eax
mov ecx, esi
call fcn.0040363c
mov esi, eax
call fcn.00409d00
jmp 0x409f79
lea ecx, [ebp - 0x84]
call fcn.00403014
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x88]
call fcn.0040209b
mov byte [ebp - 4], 3
push str._StartTP
push edi
call esi
test eax, eax
pop ecx
pop ecx
je 0x409f3d
push str._AutoRun
push edi
call esi
test eax, eax
pop ecx
pop ecx
jne 0x409f0c
call fcn.00409949
mov ecx, eax
call fcn.0040dbdc
jmp 0x409f3d
push str._debug
push edi
call dword [sym.imp.MSVCR71.dll_wcscmp]
test eax, eax
pop ecx
pop ecx
je 0x409f31
push 0x4212e0
push edi
call esi
test eax, eax
pop ecx
pop ecx
je 0x409f31
or esi, 0xffffffff
jmp 0x409f5b
call fcn.00409901
mov ecx, eax
call fcn.0040a10c
xor esi, esi
call fcn.00409901
mov ecx, eax
call fcn.0040cb68
push str.Calling_into_UnInitReplaceProgram_...
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
call fcn.0041a530
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x88]
call fcn.00401f4e
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x84]
call fcn.00403091
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x2c]
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x80]
call fcn.0040955c
mov ecx, dword [ebp - 0xc]
pop edi
mov dword fs:[0], ecx
mov ecx, dword [ebp - 0x10]
mov eax, esi
pop esi
xor ecx, ebp
pop ebx
call fcn.0041ac61
leave
ret 0x10