Function at 0x4db510
Capabilities:
Reference sql statements

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x549910
mov eax, dword fs:[0]
push eax
sub esp, 0x60
mov eax, dword [0x5b2920]
xor eax, esp
mov dword [esp + 0x58], eax
push ebx
push esi
push edi
mov eax, dword [0x5b2920]
xor eax, esp
push eax
lea eax, [esp + 0x70]
mov dword fs:[0], eax
mov ebx, ecx
mov eax, dword [ebx + 4]
xor esi, esi
cmp eax, esi
mov edi, edx
mov dword [esp + 0x24], edi
je 0x4db746
mov ecx, dword [ebx + 8]
sub ecx, eax
sar ecx, 2
je 0x4db746
cmp ecx, esi
ja 0x4db573
call fcn.00510270
mov eax, dword [ebx + 4]
mov eax, dword [eax]
cmp eax, esi
mov dword [esp + 0x14], eax
je 0x4db746
mov dword [esp + 0x64], 7
mov dword [esp + 0x60], esi
mov word [esp + 0x50], si
mov dword [esp + 0x78], esi
mov ecx, dword [ebx + 0x4c]
mov edx, dword [ecx + 4]
lea esi, [ebx + 0x48]
push edx
mov ecx, esi
mov dword [esp + 0x14], esi
call fcn.004dc850
mov eax, dword [esi + 4]
mov dword [eax + 4], eax
mov eax, dword [esi + 4]
mov dword [esi + 8], 0
mov dword [eax], eax
mov esi, dword [esi + 4]
mov dword [esi + 8], esi
mov dword [ebx + 0x54], edi
mov eax, dword [edi + 4]
mov ebx, dword [eax]
mov esi, edi
mov dword [esp + 0x20], ebx
mov dword [esp + 0x1c], esi
jmp 0x4db5e0
test esi, esi
mov eax, dword [edi + 4]
mov dword [esp + 0x2c], eax
je 0x4db5ef
cmp esi, edi
je 0x4db5f4
call fcn.00510270
cmp ebx, dword [esp + 0x2c]
je 0x4db74a
test esi, esi
jne 0x4db607
call fcn.00510270
cmp ebx, dword [esi + 4]
jne 0x4db611
call fcn.00510270
mov ecx, dword [ebx + 0x10]
lea eax, [ebx + 0x10]
push ecx
push str.SELECT_ValueInt__ValueString_FROM__t_t_t_t_t___T_PersonalSetting_WHERE_OptionID___d_
lea esi, [esp + 0x54]
mov dword [esp + 0x20], eax
call fcn.004151f0
mov ebx, dword [esp + 0x1c]
add esp, 8
mov edi, esi
call fcn.004e3130
test al, al
je 0x4db732
mov edx, dword [ebx + 4]
push edx
call sub.sqlite3.dll_sqlite3_step
add esp, 4
sub eax, 0x64
jne 0x4db6d6
push eax
mov eax, dword [ebx + 4]
push eax
call sub.sqlite3.dll_sqlite3_column_type
add esp, 8
cmp eax, 5
je 0x4db679
mov ecx, dword [ebx + 4]
push 0
push ecx
call sub.sqlite3.dll_sqlite3_column_int
add esp, 8
mov esi, eax
jmp 0x4db67b
xor esi, esi
mov edi, dword [esp + 0x18]
mov ecx, dword [esp + 0x10]
mov edx, edi
call fcn.004dc320
mov dword [eax], esi
mov eax, 1
lea esi, [esp + 0x30]
call fcn.004e2f20
mov esi, eax
mov ecx, dword [esp + 0x10]
mov edx, edi
mov byte [esp + 0x78], 1
call fcn.004dc320
push 0xffffffffffffffff
add eax, 4
push 0
push esi
mov ecx, eax
call fcn.004025b0
mov byte [esp + 0x78], 0
cmp dword [esp + 0x48], 8
jb 0x4db718
mov edx, dword [esp + 0x34]
push edx
call fcn.004e946d
add esp, 4
jmp 0x4db718
mov esi, dword [esp + 0x18]
mov ebx, dword [esp + 0x10]
mov edx, esi
mov ecx, ebx
call fcn.004dc320
mov ecx, dword [esi + 0x10]
mov dword [eax], ecx
mov edi, dword [esi + 0xc]
mov edx, esi
mov ecx, ebx
call fcn.004dc320
mov edx, edi
add eax, 4
lea esi, [edx + 2]
mov cx, word [edx]
add edx, 2
test cx, cx
jne 0x4db700
sub edx, esi
sar edx, 1
push edx
push edi
mov ecx, eax
call fcn.004029f0
lea esi, [esp + 0x1c]
call fcn.004d11c0
mov ebx, dword [esp + 0x20]
mov esi, dword [esp + 0x1c]
mov edi, dword [esp + 0x24]
jmp 0x4db5e0
cmp dword [esp + 0x64], 8
jb 0x4db746
mov edx, dword [esp + 0x50]
push edx
call fcn.004e946d
add esp, 4
xor al, al
jmp 0x4db760
cmp dword [esp + 0x64], 8
jb 0x4db75e
mov eax, dword [esp + 0x50]
push eax
call fcn.004e946d
add esp, 4
mov al, 1
mov ecx, dword [esp + 0x70]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x58]
xor ecx, esp
call fcn.0050fe87
mov esp, ebp
pop ebp
ret