Function at 0x519207
Capabilities:
Accept command line arguments
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
push ebx
push esi
mov esi, dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
push edi
mov edi, ecx
push edi
call esi
lea eax, [edi + 0x18]
push eax
call esi
xor ebx, ebx
lea esi, [edi + 0x26c]
mov dword [edi + 0x260], ebx
mov ecx, esi
mov dword [edi + 0x264], ebx
mov dword [edi + 0x268], ebx
mov dword [esi], ebx
mov dword [esi + 4], ebx
call fcn.0051a5c8
mov dword [esi], eax
xor ecx, ecx
inc ecx
mov dword [edi + 0x248], ebx
mov byte [edi + 0x259], cl
mov byte [edi + 0x258], cl
mov byte [edi + 0x25a], cl
mov ecx, esi
mov dword [edi + 0x30], ebx
mov dword [edi + 0x24c], 2
mov dword [edi + 0x250], 3
mov dword [edi + 0x254], 0x3e8
mov byte [edi + 0x25b], bl
call fcn.0051a9ff
push ebx
lea eax, [ebp - 4]
mov dword [edi + 0x25c], ebx
push eax
push ebx
push 0xf003f
push ebx
push ebx
push ebx
push str.SoftWareTencentQQ
push reloc.WS2_32.dll_accept
mov dword [ebp - 0x10], ebx
mov esi, ebx
mov dword [ebp - 4], ebx
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
test eax, eax
jne 0x519349
lea eax, [ebp - 0xc]
mov dword [ebp - 8], ebx
push eax
lea eax, [ebp - 0x10]
mov dword [ebp - 0xc], 4
push eax
lea eax, [ebp - 8]
push eax
push ebx
push str.LogSetting
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x5192ff
cmp dword [ebp - 8], 4
jne 0x5192ff
cmp dword [ebp - 0xc], 4
push 1
pop eax
cmove esi, eax
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test esi, esi
je 0x519349
mov eax, dword [ebp - 0x10]
mov ecx, eax
push 2
shr ecx, 0x10
pop edx
movzx eax, ax
mov dword [edi + 0x24c], ecx
mov dword [edi + 0x250], eax
cmp ecx, edx
je 0x519335
cmp ecx, 3
je 0x519335
mov dword [edi + 0x24c], edx
cmp eax, 3
jl 0x51933f
cmp eax, 0xa
jle 0x519349
mov dword [edi + 0x250], 3
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 0x18], ebx
mov dword [ebp - 0x14], ebx
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
push eax
lea ecx, [ebp - 0xc]
call sym.txupd.exe_public:_void___thiscall_CTXStringW::constructor_wchar_t__
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 0xc]
push eax
call sym.txupd.exe_void___cdecl_Util::Convert::SplitCmdString_class_CTXStringW_const___class_std::vector_class_CTXStringW__class_std::allocator_class_CTXStringW____
pop ecx
pop ecx
lea ecx, [ebp - 0xc]
call sym.txupd.exe_public:_void___thiscall_CTXStringW::destructor_void_
mov ebx, dword [ebp - 0x18]
xor edx, edx
mov ecx, dword [ebp - 0x1c]
inc edx
sub ebx, ecx
mov dword [ebp - 0xc], edx
sar ebx, 2
mov eax, edx
cmp ebx, edx
jbe 0x51943d
lea ecx, [ecx + eax*4]
call sym.txupd.exe_public:_wchar_t_const____thiscall_CTXStringW::operator_wchar_t_const__void_const
mov esi, eax
test esi, esi
je 0x51942a
cmp word [esi], 0x2f
jne 0x5193cb
movzx ecx, word [esi + 2]
push ecx
call fcn.006af931
pop ecx
test eax, eax
je 0x5193cb
xor eax, eax
cmp word [esi + 4], ax
jne 0x5193cb
movzx eax, word [esi + 2]
sub eax, 0x30
jmp 0x5193e9
push 0xa
push str._loglevel:
push esi
call fcn.006af9d2
add esp, 0xc
test eax, eax
jne 0x5193f1
lea eax, [esi + 0x14]
push eax
call fcn.006aca8f
pop ecx
mov dword [edi + 0x24c], eax
jmp 0x51942a
push 8
push str._logbuf:
push esi
call fcn.006af9d2
add esp, 0xc
test eax, eax
jne 0x51942a
lea eax, [edi + 0x254]
push eax
push esi
call sym.txupd.exe_bool___cdecl_Util::Convert::StringToDWordW_wchar_t_const___unsigned_long_int__
lea eax, [edi + 0x254]
add dword [eax], 8
cmp dword [eax], 1
pop ecx
pop ecx
ja 0x51942a
xor eax, eax
mov byte [edi + 0x259], al
mov eax, dword [ebp - 0xc]
inc eax
mov dword [ebp - 0xc], eax
cmp eax, ebx
jae 0x51943d
mov ecx, dword [ebp - 0x1c]
jmp 0x519393
mov ecx, edi
call fcn.0051a4fb
test eax, eax
jne 0x51944e
mov byte [edi + 0x258], al
mov ecx, edi
call fcn.0051999e
lea ecx, [ebp - 0x1c]
call fcn.005014ba
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret