Function at 0x60daa0
Capabilities:
Reference sql statements

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
mov edx, dword [ebp + 0x18]
push ebx
push esi
xor esi, esi
mov dword [ebp - 0xc], 0
mov ecx, dword [edx + 4]
push edi
mov dword [ebp - 4], esi
mov dword [ebp - 8], esi
lea edi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x60dac1
sub ecx, edi
lea eax, [ecx + 1]
mov ecx, dword [edx + 8]
mov dword [ebp - 0x14], eax
lea edi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x60dad6
mov ebx, dword [ebp + 0x14]
sub ecx, edi
mov edi, 3
lea eax, [ecx + 1]
mov ecx, dword [ebp + 0x20]
mov dword [ebp - 0x10], eax
cmp ebx, edi
jle 0x60db40
mov esi, dword [edx + edi*4]
lea eax, [ebp - 4]
push ecx
push eax
lea eax, [ebp - 8]
push eax
push esi
push dword [ebp + 0x10]
call fcn.00633530
add esp, 0x14
test eax, eax
jne 0x60e05d
cmp esi, dword [ebp - 4]
je 0x60db32
lea ecx, [esi + 1]
nop dword [eax]
mov al, byte [esi]
inc esi
test al, al
jne 0x60db20
mov eax, dword [ebp - 0xc]
sub esi, ecx
inc eax
add eax, esi
mov dword [ebp - 0xc], eax
mov edx, dword [ebp + 0x18]
inc edi
mov ecx, dword [ebp + 0x20]
cmp edi, ebx
jl 0x60daf4
mov esi, dword [ebp - 4]
xor eax, eax
mov edi, ebx
test esi, esi
setne al
sub edi, eax
sub edi, 3
test esi, esi
jne 0x60db6c
push ecx
push esi
lea eax, [ebp - 8]
push eax
push esi
push dword [ebp + 0x10]
call fcn.00633530
add esp, 0x14
test eax, eax
jne 0x60e05d
mov ebx, dword [ebp - 0xc]
mov eax, 1
test edi, edi
cmove edi, eax
mov eax, dword [ebp - 0x10]
add ebx, 0xd0
lea eax, [eax + edi*4]
add eax, dword [ebp - 0x14]
add ebx, eax
mov dword [ebp + 0x10], ebx
call fcn.00658040
test eax, eax
jne 0x60e048
push ebx
call fcn.0063b730
mov ebx, eax
add esp, 4
test ebx, ebx
je 0x60e048
push dword [ebp + 0x10]
push 0
push ebx
call fcn.005bc9a0
mov eax, dword [ebp + 0xc]
lea ecx, [ebx + 0xd0]
push dword [ebp - 0x10]
mov dword [ebx + 0xc], eax
mov dword [ebx + 0x18], edi
lea edi, [ecx + edi*4]
mov dword [ebx + 0x1c], ecx
mov dword [ebx + 0xa8], 0
mov eax, dword [ebp - 8]
mov dword [ebx + 0x20], eax
mov eax, dword [ebp + 0x18]
mov word [ebx + 0xb8], 0x101
mov dword [ebx + 0xc0], 0
mov dword [ebx + 0xbc], 0
mov dword [ebx + 0xc4], 0
mov dword [ebx + 0xc8], 0
mov dword [ebx + 0x9c], 0x3e8
mov dword [ebx + 0xa4], 0x100000
mov dword [ebx + 0x14], edi
push dword [eax + 8]
push edi
call fcn.005bcb70
mov eax, dword [ebp + 0x18]
add edi, dword [ebp - 0x10]
push dword [ebp - 0x14]
mov dword [ebx + 0x10], edi
push dword [eax + 4]
push edi
call fcn.005bcb70
add edi, dword [ebp - 0x14]
xor edx, edx
mov dword [ebp + 0x10], edi
add esp, 0x24
mov edi, 3
mov dword [ebp - 0x14], edx
cmp dword [ebp + 0x14], edi
jle 0x60dcb7
mov eax, dword [ebp + 0x18]
mov eax, dword [eax + edi*4]
cmp eax, esi
je 0x60dcad
lea ecx, [ebp - 0x10]
push ecx
push eax
call fcn.006339c0
mov esi, dword [ebp - 0x10]
mov ecx, dword [ebp + 0x10]
push esi
push eax
push ecx
call fcn.005bcb70
mov eax, dword [ebp + 0x10]
add esi, eax
push eax
mov byte [esi], 0
call fcn.00632d30
mov edx, dword [ebp - 0x14]
add esp, 0x18
mov eax, dword [ebx + 0x1c]
mov ecx, dword [ebp + 0x10]
mov dword [eax + edx*4], ecx
lea eax, [esi + 1]
mov esi, dword [ebp - 4]
inc edx
mov dword [ebp - 0x14], edx
mov dword [ebp + 0x10], eax
inc edi
cmp edi, dword [ebp + 0x14]
jl 0x60dc61
test edx, edx
jne 0x60dcc0
mov eax, dword [ebx + 0x1c]
mov dword [eax], 0x6b74d0
cmp dword [ebp + 8], 0
mov eax, dword [ebp + 0x18]
je 0x60de22
mov byte [ebx + 0xa0], 1
mov eax, dword [eax]
push str.docid_INTEGER_PRIMARY_KEY
mov dword [ebp + 0x18], 0
cmp byte [eax + 3], 0x34
sete al
mov byte [ebx + 0xa1], al
mov eax, dword [ebx + 0xc]
mov dword [ebp + 0x14], eax
call fcn.005f7a20
mov edi, eax
add esp, 4
xor esi, esi
test edi, edi
je 0x60dd26
cmp esi, dword [ebx + 0x18]
jge 0x60dd2d
mov eax, dword [ebx + 0x1c]
push dword [eax + esi*4]
push esi
push edi
push str._z__c_d_q
call fcn.005f7a20
mov edi, eax
add esp, 0x10
inc esi
test edi, edi
jne 0x60dd05
mov dword [ebp + 0x18], 7
mov esi, dword [ebp + 0x14]
lea eax, [ebp + 0x18]
push edi
push dword [ebx + 0x14]
push dword [ebx + 0x10]
push str.CREATE_TABLE__Q._q_content__s_
push esi
push eax
call fcn.0060c140
add esp, 0x18
test edi, edi
je 0x60ddb7
cmp dword [0x6f1bb8], 0
je 0x60ddad
mov eax, dword [0x6ff2f0]
test eax, eax
je 0x60dd69
push eax
call dword [0x6f1c00]
add esp, 4
push edi
call dword [0x6f1bdc]
mov ecx, dword [0x6ff1b8]
neg eax
add ecx, eax
add esp, 4
mov dword [0x6ff1b8], ecx
cmp ecx, dword [0x6ff1dc]
jle 0x60dd91
mov dword [0x6ff1dc], ecx
push edi
call dword [0x6f1bd4]
mov eax, dword [0x6ff2f0]
add esp, 4
test eax, eax
je 0x60ddb7
push eax
call dword [0x6f1c08]
jmp 0x60ddb4
push edi
call dword [0x6f1bd4]
add esp, 4
push dword [ebx + 0x14]
lea eax, [ebp + 0x18]
push dword [ebx + 0x10]
push str.CREATE_TABLE__Q._q_segments_blockid_INTEGER_PRIMARY_KEY__block_BLOB__
push esi
push eax
call fcn.0060c140
push dword [ebx + 0x14]
lea eax, [ebp + 0x18]
push dword [ebx + 0x10]
push str.CREATE_TABLE__Q._q_segdir_level_INTEGER_idx_INTEGER_start_block_INTEGER_leaves_end_block_INTEGER_end_block_INTEGER_root_BLOB_PRIMARY_KEY_level__idx___
push esi
push eax
call fcn.0060c140
add esp, 0x28
cmp byte [ebx + 0xa1], 0
je 0x60de1a
push dword [ebx + 0x14]
lea eax, [ebp + 0x18]
push dword [ebx + 0x10]
push str.CREATE_TABLE__Q._q_docsize_docid_INTEGER_PRIMARY_KEY__size_BLOB__
push esi
push eax
call fcn.0060c140
push dword [ebx + 0x14]
lea eax, [ebp + 0x18]
push dword [ebx + 0x10]
push str.CREATE_TABLE__Q._q_stat_id_INTEGER_PRIMARY_KEY__value_BLOB__
push esi
push eax
call fcn.0060c140
add esp, 0x28
mov edi, dword [ebp + 0x18]
jmp 0x60dec8
push str._content
push dword [eax + 8]
mov dword [ebp + 0x14], 0
push dword [eax + 4]
push str.SELECT_1_FROM__Q.sqlite_master_WHERE_name_q_s
call fcn.005f7a20
mov edi, eax
lea eax, [ebp + 0x14]
push 0
push eax
push 0x612280
push edi
push dword [ebp + 0xc]
call fcn.005f51f0
push edi
mov esi, eax
call fcn.005f7d20
mov cl, byte [ebp + 0x14]
add esp, 0x28
mov eax, dword [ebp + 0x18]
cmp esi, 4
mov edi, 0
mov byte [ebx + 0xa0], cl
cmovne edi, esi
mov dword [ebp + 0x18], 0
test edi, edi
jne 0x60e036
push str._docsize
push dword [eax + 8]
push dword [eax + 4]
push str.SELECT_1_FROM__Q.sqlite_master_WHERE_name_q_s
call fcn.005f7a20
mov esi, eax
lea eax, [ebp + 0x18]
push edi
push eax
push 0x612280
push esi
push dword [ebp + 0xc]
call fcn.005f51f0
push esi
mov edi, eax
call fcn.005f7d20
mov al, byte [ebp + 0x18]
add esp, 0x28
mov byte [ebx + 0xa1], al
cmp edi, 4
je 0x60ded0
test edi, edi
jne 0x60e036
mov eax, dword [ebx + 0x1c]
push dword [eax]
push str._Q_
call fcn.005f7a20
mov esi, eax
add esp, 8
mov edi, 1
test esi, esi
je 0x60df10
nop dword [eax]
cmp edi, dword [ebx + 0x18]
jge 0x60df10
mov eax, dword [ebx + 0x1c]
push dword [eax + edi*4]
push esi
push str._z_Q_
call fcn.005f7a20
mov esi, eax
add esp, 0xc
inc edi
test esi, esi
jne 0x60def0
push dword [ebx + 0x14]
push esi
push str.CREATE_TABLE_x__s__Q_HIDDEN__docid_HIDDEN_
call fcn.005f7a20
add esp, 0xc
mov dword [ebp + 0x18], eax
test esi, esi
je 0x60df3f
test eax, eax
je 0x60df3f
push eax
push dword [ebx + 0xc]
call fcn.005ed960
mov edi, eax
add esp, 8
mov eax, dword [ebp + 0x18]
jmp 0x60df48
mov edi, 7
test eax, eax
je 0x60dfb6
cmp dword [0x6f1bb8], 0
je 0x60dfac
mov eax, dword [0x6ff2f0]
test eax, eax
je 0x60df64
push eax
call dword [0x6f1c00]
add esp, 4
push dword [ebp + 0x18]
call dword [0x6f1bdc]
mov ecx, dword [0x6ff1b8]
neg eax
add ecx, eax
add esp, 4
mov dword [0x6ff1b8], ecx
cmp ecx, dword [0x6ff1dc]
jle 0x60df8e
mov dword [0x6ff1dc], ecx
push dword [ebp + 0x18]
call dword [0x6f1bd4]
mov eax, dword [0x6ff2f0]
add esp, 4
test eax, eax
je 0x60dfbb
push eax
call dword [0x6f1c08]
jmp 0x60dfb3
push eax
call dword [0x6f1bd4]
add esp, 4
mov eax, dword [0x6ff2f0]
test esi, esi
je 0x60e024
cmp dword [0x6f1bb8], 0
je 0x60e01a
test eax, eax
je 0x60dfd6
push eax
call dword [0x6f1c00]
add esp, 4
push esi
call dword [0x6f1bdc]
mov ecx, dword [0x6ff1b8]
neg eax
add ecx, eax
add esp, 4
mov dword [0x6ff1b8], ecx
cmp ecx, dword [0x6ff1dc]
jle 0x60dffe
mov dword [0x6ff1dc], ecx
push esi
call dword [0x6f1bd4]
mov eax, dword [0x6ff2f0]
add esp, 4
test eax, eax
je 0x60e024
push eax
call dword [0x6f1c08]
jmp 0x60e021
push esi
call dword [0x6f1bd4]
add esp, 4
test edi, edi
jne 0x60e036
mov eax, dword [ebp + 0x1c]
mov dword [eax], ebx
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push ebx
call fcn.005f2820
add esp, 4
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 8]
mov edi, 7
push ecx
mov edx, dword [ecx]
mov ecx, dword [edx + 8]
call ecx
add esp, 4
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret