Function at 0x40ae80
Capabilities:
Accept command line arguments
Check mutex on windows
Get common file path
Print debug messages

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5009ac
mov eax, dword fs:[0]
push eax
sub esp, 0xc34
mov eax, dword [0x5470bc]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, dword [ebp + 8]
mov ebx, dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
push str.wWinMain____r_n
mov dword [ebp - 0xc0c], esi
call ebx
push str.ZZDS_InsClass
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateMutexW]
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x40af0f
push 0x532e38
push str.ZZDS_InsClass
call dword [sym.imp.USER32.dll_FindWindowW]
mov esi, eax
test esi, esi
je 0x40b6a5
push 1
push esi
call dword [sym.imp.USER32.dll_ShowWindow]
push esi
call dword [sym.imp.USER32.dll_SetForegroundWindow]
jmp 0x40b6a5
call fcn.004055a0
mov ecx, eax
call fcn.00405640
push 0x208
lea eax, [ebp - 0x218]
push 0
push eax
call fcn.004d8530
add esp, 0xc
lea eax, [ebp - 0x218]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
push 0x18
xor eax, eax
mov dword [ebp - 0xbf4], 7
push str.GetCurrentDirectoryW____
lea ecx, [ebp - 0xc08]
mov dword [ebp - 0xbf8], 0
mov word [ebp - 0xc08], ax
call fcn.004020c0
push 0x532e58
lea eax, [ebp - 0x218]
push eax
lea eax, [ebp - 0xc08]
push eax
lea eax, [ebp - 0xbf0]
push eax
call fcn.00408660
add esp, 0xc
push eax
lea eax, [ebp - 0xc24]
push eax
call fcn.00408660
add esp, 0xc
push eax
call fcn.004055a0
mov ecx, eax
call fcn.004056d0
mov eax, dword [ebp - 0xc10]
cmp eax, 8
jb 0x40afcf
inc eax
lea ecx, [ebp - 0xc24]
push eax
push dword [ebp - 0xc24]
call fcn.004024e0
xor eax, eax
mov dword [ebp - 0xc10], 7
mov word [ebp - 0xc24], ax
mov eax, dword [ebp - 0xbdc]
mov dword [ebp - 0xc14], 0
cmp eax, 8
jb 0x40b00a
inc eax
lea ecx, [ebp - 0xbf0]
push eax
push dword [ebp - 0xbf0]
call fcn.004024e0
xor eax, eax
mov dword [ebp - 0xbdc], 7
mov word [ebp - 0xbf0], ax
mov eax, dword [ebp - 0xbf4]
mov dword [ebp - 0xbe0], 0
cmp eax, 8
jb 0x40b045
inc eax
lea ecx, [ebp - 0xc08]
push eax
push dword [ebp - 0xc08]
call fcn.004024e0
push 0x208
lea eax, [ebp - 0x420]
push 0
push eax
call fcn.004d8530
add esp, 0xc
lea eax, [ebp - 0x420]
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
push 0x17
xor eax, eax
mov dword [ebp - 0xbf4], 7
push str.GetSystemDirectoryW____
lea ecx, [ebp - 0xc08]
mov dword [ebp - 0xbf8], 0
mov word [ebp - 0xc08], ax
call fcn.004020c0
push 0x532e58
lea eax, [ebp - 0x420]
push eax
lea eax, [ebp - 0xc08]
push eax
lea eax, [ebp - 0xc24]
push eax
call fcn.00408660
add esp, 0xc
push eax
lea eax, [ebp - 0xbf0]
push eax
call fcn.00408660
add esp, 0xc
push eax
call fcn.004055a0
mov ecx, eax
call fcn.004056d0
mov eax, dword [ebp - 0xbdc]
cmp eax, 8
jb 0x40b0f9
inc eax
lea ecx, [ebp - 0xbf0]
push eax
push dword [ebp - 0xbf0]
call fcn.004024e0
xor eax, eax
mov dword [ebp - 0xbdc], 7
mov word [ebp - 0xbf0], ax
mov eax, dword [ebp - 0xc10]
mov dword [ebp - 0xbe0], 0
cmp eax, 8
jb 0x40b134
inc eax
lea ecx, [ebp - 0xc24]
push eax
push dword [ebp - 0xc24]
call fcn.004024e0
xor eax, eax
mov dword [ebp - 0xc10], 7
mov word [ebp - 0xc24], ax
mov eax, dword [ebp - 0xbf4]
mov dword [ebp - 0xc14], 0
cmp eax, 8
jb 0x40b16f
inc eax
lea ecx, [ebp - 0xc08]
push eax
push dword [ebp - 0xc08]
call fcn.004024e0
mov dword [ebp - 0x43c], 0
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
lea ecx, [ebp - 0x43c]
mov dword [ebp - 0xc28], eax
push ecx
push eax
call dword [sym.imp.SHELL32.dll_CommandLineToArgvW]
mov ecx, dword [ebp - 0x43c]
mov edi, eax
cmp ecx, 1
jle 0x40b54e
xor eax, eax
mov dword [ebp - 0x424], 7
xor bh, bh
mov dword [ebp - 0x428], 0
mov bl, 1
mov word [ebp - 0x438], ax
lea esi, [eax + 1]
cmp ecx, esi
jle 0x40b262
push 0x532ec4
push dword [edi + esi*4]
call fcn.004de58d
add esp, 8
test eax, eax
jne 0x40b1e8
mov bh, 1
jmp 0x40b255
push 0x532ecc
push dword [edi + esi*4]
call fcn.004de58d
add esp, 8
test eax, eax
jne 0x40b23f
inc esi
cmp esi, dword [ebp - 0x43c]
jge 0x40b255
mov edx, dword [edi + esi*4]
lea ecx, [ebp - 0xbf0]
call fcn.0040ad60
push eax
lea ecx, [ebp - 0x438]
call fcn.00406880
mov eax, dword [ebp - 0xbdc]
cmp eax, 8
jb 0x40b255
inc eax
lea ecx, [ebp - 0xbf0]
push eax
push dword [ebp - 0xbf0]
call fcn.004024e0
jmp 0x40b255
push 0x532ed4
push dword [edi + esi*4]
call fcn.004de58d
add esp, 8
neg eax
sbb al, al
and bl, al
inc esi
cmp esi, dword [ebp - 0x43c]
jl 0x40b1d0
push edi
call dword [sym.imp.KERNEL32.dll_LocalFree]
test bh, bh
je 0x40b524
push 0xf
xor eax, eax
mov dword [ebp - 0xbf4], 7
push 0x532edc
lea ecx, [ebp - 0xc08]
mov dword [ebp - 0xbf8], 0
mov word [ebp - 0xc08], ax
call fcn.004020c0
push dword [ebp - 0xc28]
lea eax, [ebp - 0xc08]
push eax
lea eax, [ebp - 0xbf0]
push eax
call fcn.00408660
add esp, 0xc
push eax
call fcn.004055a0
mov ecx, eax
call fcn.004056d0
mov eax, dword [ebp - 0xbdc]
cmp eax, 8
jb 0x40b2e7
inc eax
lea ecx, [ebp - 0xbf0]
push eax
push dword [ebp - 0xbf0]
call fcn.004024e0
xor eax, eax
mov dword [ebp - 0xbdc], 7
mov word [ebp - 0xbf0], ax
mov eax, dword [ebp - 0xbf4]
mov dword [ebp - 0xbe0], 0
cmp eax, 8
jb 0x40b322
inc eax
lea ecx, [ebp - 0xc08]
push eax
push dword [ebp - 0xc08]
call fcn.004024e0
cmp dword [ebp - 0x428], 0
je 0x40b34c
cmp dword [ebp - 0x424], 8
lea ecx, [ebp - 0x438]
cmovae ecx, dword [ebp - 0x438]
call fcn.00418220
test al, al
jne 0x40b3d5
call fcn.0040baf0
lea eax, [ebp - 0xbf0]
push eax
call fcn.0040c560
mov esi, eax
lea eax, [ebp - 0x438]
cmp eax, esi
je 0x40b3b0
mov eax, dword [ebp - 0x424]
cmp eax, 8
jb 0x40b387
inc eax
lea ecx, [ebp - 0x438]
push eax
push dword [ebp - 0x438]
call fcn.004024e0
xor eax, eax
mov dword [ebp - 0x424], 7
push esi
lea ecx, [ebp - 0x438]
mov dword [ebp - 0x428], 0
mov word [ebp - 0x438], ax
call fcn.00407b80
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0xbdc]
cmp eax, 8
jb 0x40b3d5
inc eax
lea ecx, [ebp - 0xbf0]
push eax
push dword [ebp - 0xbf0]
call fcn.004024e0
cmp dword [ebp - 0x424], 8
lea ecx, [ebp - 0x438]
cmovae ecx, dword [ebp - 0x438]
call fcn.00418220
test al, al
jne 0x40b47f
call fcn.0040baf0
lea eax, [ebp - 0xbf0]
push eax
call fcn.0040c480
mov esi, eax
lea eax, [ebp - 0x438]
cmp eax, esi
je 0x40b45a
mov eax, dword [ebp - 0x424]
cmp eax, 8
jb 0x40b431
inc eax
lea ecx, [ebp - 0x438]
push eax
push dword [ebp - 0x438]
call fcn.004024e0
xor eax, eax
mov dword [ebp - 0x424], 7
push esi
lea ecx, [ebp - 0x438]
mov dword [ebp - 0x428], 0
mov word [ebp - 0x438], ax
call fcn.00407b80
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0xbdc]
cmp eax, 8
jb 0x40b47f
inc eax
lea ecx, [ebp - 0xbf0]
push eax
push dword [ebp - 0xbf0]
call fcn.004024e0
cmp dword [ebp - 0x424], 8
lea eax, [ebp - 0x438]
cmovae eax, dword [ebp - 0x438]
push eax
push ecx
call fcn.0040baf0
add esp, 4
mov ecx, eax
call fcn.0040c6f0
test bl, bl
je 0x40b4bc
sub esp, 8
call fcn.0040baf0
add esp, 4
mov ecx, eax
call fcn.0040d130
jmp 0x40b4fd
push 0x532efc
lea ecx, [ebp - 0xbf0]
call fcn.00401f30
lea eax, [ebp - 0xbf0]
push eax
call fcn.004055a0
mov ecx, eax
call fcn.004056d0
mov eax, dword [ebp - 0xbdc]
cmp eax, 8
jb 0x40b4fd
inc eax
lea ecx, [ebp - 0xbf0]
push eax
push dword [ebp - 0xbf0]
call fcn.004024e0
mov eax, dword [ebp - 0x424]
cmp eax, 8
jb 0x40b6a5
inc eax
lea ecx, [ebp - 0x438]
push eax
push dword [ebp - 0x438]
call fcn.004024e0
jmp 0x40b6a5
mov eax, dword [ebp - 0x424]
cmp eax, 8
jb 0x40b542
inc eax
lea ecx, [ebp - 0x438]
push eax
push dword [ebp - 0x438]
call fcn.004024e0
mov esi, dword [ebp - 0xc0c]
mov ebx, dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
push 9
xor eax, eax
mov dword [ebp - 0xc2c], 7
push 0x532f14
lea ecx, [ebp - 0xc40]
mov dword [ebp - 0xc30], 0
mov word [ebp - 0xc40], ax
call fcn.004020c0
lea eax, [ebp - 0xc40]
push eax
call fcn.004055a0
mov ecx, eax
call fcn.004056d0
mov eax, dword [ebp - 0xc2c]
cmp eax, 8
jb 0x40b5ae
inc eax
lea ecx, [ebp - 0xc40]
push eax
push dword [ebp - 0xc40]
call fcn.004024e0
xor eax, eax
mov dword [ebp - 0xc2c], 7
push eax
mov dword [ebp - 0xc30], 0
mov word [ebp - 0xc40], ax
call dword [sym.imp.ole32.dll_CoInitialize]
push 3
call fcn.00427b20
add esp, 4
mov ecx, esi
call fcn.0040ac20
push 0x794
lea eax, [ebp - 0xbd8]
push 0
push eax
call fcn.004d8530
add esp, 0xc
lea ecx, [ebp - 0xbd8]
call fcn.004145d0
push 0
push accept
push accept
push accept
push accept
push 0x100
push 0x10080000
push 0x532e38
push 0
lea ecx, [ebp - 0xbd8]
call fcn.0046bbe0
lea ecx, [ebp - 0xbd8]
call fcn.0046ba70
lea ecx, [ebp - 0xbd8]
call fcn.0046c080
call fcn.00427ae0
call dword [sym.imp.ole32.dll_CoUninitialize]
push str.CMainWnd::CMainWnd____r_n
mov dword [ebp - method.CMainWnd.2.virtual_0], vtable.CMainWnd.2.0
mov dword [ebp - method.CXMLWnd.virtual_0], vtable.CMainWnd.5.0
mov dword [ebp - method.CMainWnd.1.virtual_0], vtable.CMainWnd.1.0
mov dword [ebp - method.DuiLib::WindowImplBase.1.virtual_0], vtable.CMainWnd.3.0
mov dword [ebp - method.CMainWnd.virtual_0], vtable.CMainWnd.0
mov dword [ebp - method.DuiLib::CActiveXFrameWnd.virtual_16], vtable.CMainWnd.4.0
call ebx
lea ecx, [ebp - 0xbd8]
call fcn.004141e0
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004264c2
mov esp, ebp
pop ebp
ret 0x10