Function at 0x459513
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x40
cmp dword [ebp + 8], 0
push ebx
push esi
mov esi, ecx
mov dword [ebp - 0x24], edx
push edi
mov dword [ebp - 0x10], esi
mov edi, dword [esi]
mov dword [ebp - 0x14], edi
jne 0x459539
cmp dword [ebp + 0x10], 0
je 0x4598bd
mov ebx, dword [esi + 0x1b4]
test ebx, ebx
je 0x4598bd
cmp byte [edi + 0x99], 0
je 0x459561
mov eax, dword [edi + 0x94]
mov dword [ebx + 0x1c], eax
cmp eax, 1
jne 0x459561
or dword [ebx + 0x24], eax
test byte [ebp + 0xc], 0x20
je 0x4595a3
mov eax, dword [ebx + 0x24]
test al, 8
je 0x459580
push str.AUTOINCREMENT_not_allowed_on_WITHOUT_ROWID_tables
push esi
call fcn.0042e402
pop ecx
pop ecx
jmp 0x4598bd
test al, 4
jne 0x459596
push dword [ebx]
push str.PRIMARY_KEY_missing_on_table__s
push esi
call fcn.0042e402
add esp, 0xc
jmp 0x4595a3
or eax, 0x60
mov edx, ebx
mov dword [ebx + 0x24], eax
call fcn.004591f9
mov edx, dword [ebx + 0x48]
mov ecx, edi
call fcn.00465f4c
cmp dword [ebx + 0x18], 0
mov dword [ebp - 0xc], eax
je 0x4595c9
push dword [ebx + 0x18]
mov edx, ebx
mov ecx, esi
push 0
push 4
call fcn.00450996
add esp, 0xc
mov ecx, ebx
call fcn.0045913d
mov eax, dword [ebx + 8]
test eax, eax
je 0x4595ea
mov edi, eax
mov ecx, edi
call fcn.0045917f
mov edi, dword [edi + 0x14]
test edi, edi
jne 0x4595d9
mov edi, dword [ebp - 0x14]
mov al, byte [edi + 0x99]
test al, al
jne 0x45986f
mov ecx, esi
call fcn.00468189
mov dword [ebp - 8], eax
test eax, eax
je 0x4598bd
push 0
push 0x72
pop edx
mov ecx, eax
call fcn.00443369
mov eax, dword [ebx + 0xc]
mov edx, str.TABLE
test eax, eax
pop ecx
mov ecx, str.VIEW
cmove ecx, edx
mov edx, str.table
mov dword [ebp - 0x1c], ecx
mov ecx, str.view
cmove ecx, edx
cmp dword [ebp + 0x10], 0
mov dword [ebp - 0x20], ecx
je 0x4597a2
mov edi, dword [esi + 0x2c]
mov ecx, esi
inc edi
lea eax, [edi + 1]
mov dword [ebp - 0x1c], eax
inc eax
mov dword [ebp - 0x18], eax
mov dword [esi + 0x2c], eax
call fcn.0045b9ff
push dword [ebp - 0xc]
mov ecx, dword [ebp - 8]
push dword [esi + 0x68]
push 1
push 0x6b
pop edx
call fcn.004432f9
mov ecx, dword [ebp - 8]
add esp, 0xc
push 0x10
pop edx
call fcn.004437ff
mov dword [esi + 0x28], 2
call fcn.004436d4
mov esi, eax
lea ecx, [esi + 1]
push ecx
mov ecx, dword [ebp - 8]
push 0
push edi
push 0xf
pop edx
call fcn.004432f9
add esp, 0xc
lea ecx, [ebp - 0x3c]
push edi
push 0xd
pop edx
call fcn.00466581
mov edx, dword [ebp + 0x10]
add esp, 4
mov eax, ecx
mov ecx, dword [ebp - 0x10]
push eax
call fcn.0046afe2
pop ecx
mov ecx, dword [ebp - 8]
mov edx, edi
call fcn.0044350b
mov edx, esi
mov esi, dword [ebp - 8]
mov ecx, esi
call fcn.00443817
mov eax, dword [ebp - 0x10]
cmp dword [eax + 0x24], 0
jne 0x4598bd
mov edx, dword [ebp + 0x10]
mov ecx, eax
call fcn.004680a7
test eax, eax
je 0x4598bd
mov cx, word [eax + 0x2a]
mov edx, eax
mov edi, dword [ebp - 0x14]
mov word [ebx + 0x2a], cx
mov ecx, dword [eax + 4]
mov dword [ebx + 4], ecx
xor ecx, ecx
and dword [eax + 4], ecx
mov word [eax + 0x2a], cx
mov ecx, edi
call fcn.00458259
push dword [ebp - 0x34]
mov ecx, esi
push 0x10
pop edx
call fcn.00443369
pop ecx
push dword [ebp - 0x1c]
mov ecx, dword [ebp - 8]
mov esi, eax
push dword [ebp - 0x2c]
push dword [ebp - 0x30]
push 0x65
pop edx
call fcn.004432f9
mov ecx, dword [ebp - 8]
add esp, 0xc
mov edx, ebx
push 0
call fcn.0046051f
pop ecx
push dword [ebp - 0x18]
mov ecx, dword [ebp - 8]
push 1
push 0x75
pop edx
call fcn.0044337d
push dword [ebp - 0x18]
mov ecx, dword [ebp - 8]
push dword [ebp - 0x1c]
push 1
push 0x76
pop edx
call fcn.004432f9
mov ecx, dword [ebp - 8]
add esp, 0x14
mov edx, esi
call fcn.00443392
mov ecx, dword [ebp - 8]
mov edx, esi
call fcn.00443817
mov ecx, dword [ebp - 8]
push 1
push 0x72
pop edx
call fcn.00443369
pop ecx
mov edx, ebx
mov ecx, edi
call fcn.00458f36
mov esi, dword [ebp - 0x10]
jmp 0x4597dc
cmp byte [ebp + 0xc], 0
lea eax, [esi + 0x188]
mov edx, dword [ebp + 8]
cmovne edx, eax
mov eax, dword [edx]
mov ecx, eax
sub ecx, dword [esi + 0x180]
cmp byte [eax], 0x3b
je 0x4597c4
add ecx, dword [edx + 4]
push dword [esi + 0x180]
push ecx
push dword [ebp - 0x1c]
push str.CREATE__s__.s
push edi
call fcn.0042d86a
add esp, 0x14
push dword [esi + 0x64]
mov ecx, dword [ebp - 0xc]
push eax
push dword [esi + 0x68]
mov dword [ebp - 0x1c], eax
push dword [ebx]
mov eax, dword [edi + 0x10]
push dword [ebx]
shl ecx, 4
push dword [ebp - 0x20]
mov dword [ebp - 0x18], ecx
push str.sqlite_master
push dword [ecx + eax]
push str.UPDATE__Q._s_SET_type_s__name_Q__tbl_name_Q__rootpage_d__sql_Q_WHERE_rowid_d
push esi
call fcn.00457cb2
mov edx, dword [ebp - 0x1c]
add esp, 0x28
mov ecx, edi
call fcn.0042c1c6
mov edx, dword [ebp - 0xc]
mov ecx, esi
call fcn.00458e4c
test byte [ebx + 0x24], 8
je 0x459848
mov ecx, dword [edi + 0x10]
add ecx, dword [ebp - 0x18]
mov eax, dword [ecx + 0xc]
cmp dword [eax + 0x48], 0
jne 0x459848
push dword [ecx]
push str.CREATE_TABLE__Q.sqlite_sequence_name_seq_
push esi
call fcn.00457cb2
add esp, 0xc
push dword [ebx]
push str.tbl_name_q_AND_type_trigger
push edi
call fcn.0042d86a
mov edx, dword [ebp - 0xc]
add esp, 0xc
mov ecx, dword [ebp - 8]
push eax
call fcn.0044349d
mov al, byte [edi + 0x99]
pop ecx
test al, al
je 0x4598bd
mov ecx, dword [ebx + 0x48]
mov edx, dword [ebx]
push ebx
lea ecx, [ecx + 8]
call fcn.0042f8c3
pop ecx
test eax, eax
je 0x45988b
mov ecx, edi
call fcn.0042c5f1
jmp 0x4598bd
and dword [esi + 0x1b4], 0
or dword [edi + 0x18], 2
cmp dword [ebx + 0xc], 0
jne 0x4598bd
mov edx, dword [ebp - 0x24]
mov ecx, dword [esi + 0x180]
mov edx, dword [edx]
test edx, edx
jne 0x4598b0
mov eax, dword [ebp + 8]
mov edx, dword [eax]
sub edx, ecx
call fcn.0042e1f9
add eax, 0xd
mov dword [ebx + 0x34], eax
pop edi
pop esi
pop ebx
leave
ret