Function at 0x5fd240
Capabilities:
Reference sql statements

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
mov ecx, dword [ebp + 0x18]
mov eax, dword [ebp + 0xc]
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
test ecx, ecx
mov dword [esi + 0xc], eax
je 0x5fd315
push eax
call fcn.0057a960
mov ecx, dword [ebp + 0x10]
mov edi, eax
mov eax, dword [ebp + 0x14]
push eax
push ecx
push str.CREATE_TABLE___w_.__w_rowid__rowid_INTEGER_PRIMARY_KEY_nodeno
push edi
call fcn.0057ab60
mov al, byte [esi + 0x19]
add esp, 0x14
xor ebx, ebx
test al, al
jbe 0x5fd29d
push ebx
push str._a_d
push edi
call fcn.0057ab60
xor edx, edx
add esp, 0xc
mov dl, byte [esi + 0x19]
inc ebx
cmp ebx, edx
jl 0x5fd284
mov ebx, dword [ebp + 0x14]
mov eax, dword [ebp + 0x10]
push ebx
push eax
push str.__CREATE_TABLE___w_.__w_node__nodeno_INTEGER_PRIMARY_KEY_data__
push edi
call fcn.0057ab60
mov ecx, dword [ebp + 0x10]
push ebx
push ecx
push str.CREATE_TABLE___w_.__w_parent__nodeno_INTEGER_PRIMARY_KEY_parentnode__
push edi
call fcn.0057ab60
mov edx, dword [esi + 0x10]
mov eax, dword [ebp + 0x10]
push edx
push ebx
push eax
push str.INSERT_INTO___w_.__w_node_VALUES_1_zeroblob__d__
push edi
call fcn.0057ab60
push edi
call fcn.0057a7e0
mov edi, eax
add esp, 0x38
test edi, edi
jne 0x5fd2ef
pop edi
pop esi
mov eax, 7
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp + 0xc]
push 0
push 0
push 0
push edi
push ecx
call fcn.005acb10
push edi
mov ebx, eax
call fcn.00578d00
add esp, 0x18
test ebx, ebx
jne 0x5fd4bc
mov eax, dword [ebp + 0xc]
lea edx, [esi + 0x50]
lea ecx, [esi + 0x54]
mov dword [ebp - 0x20], edx
mov dword [ebp - 0x1c], ecx
lea edx, [esi + 0x58]
lea ecx, [esi + 0x5c]
mov dword [ebp - 0x18], edx
mov dword [ebp - 0x14], ecx
lea edx, [esi + 0x60]
lea ecx, [esi + 0x64]
mov dword [ebp - 0x10], edx
mov dword [ebp - 0xc], ecx
lea edx, [esi + 0x68]
lea ecx, [esi + 0x6c]
push esi
push eax
mov dword [ebp - 8], edx
mov dword [ebp - 4], ecx
call fcn.005fd4d0
add esp, 8
mov ebx, eax
xor eax, eax
mov dword [ebp + 8], eax
jmp 0x5fd35b
mov eax, dword [ebp + 8]
test ebx, ebx
jne 0x5fd3c9
cmp eax, 3
jne 0x5fd372
mov cl, byte [esi + 0x19]
test cl, cl
je 0x5fd372
mov eax, str.INSERT_INTO__w_.__w_rowid__rowid_nodeno_VALUES__1__2_ON_CONFLICT_rowid_DO_UPDATE_SET_nodenoexcluded.nodeno
jmp 0x5fd379
mov eax, dword [eax*4 + 0x854ce0]
mov edx, dword [ebp + 0x14]
mov ecx, dword [ebp + 0x10]
push edx
push ecx
push eax
call fcn.0057aa30
mov edi, eax
add esp, 0xc
test edi, edi
je 0x5fd3af
mov edx, dword [ebp + 8]
mov ecx, dword [ebp + 0xc]
push 0
mov eax, dword [ebp + edx*4 - 0x20]
push eax
push 5
push 0xffffffffffffffff
push edi
push ecx
call fcn.005aea50
add esp, 0x18
mov ebx, eax
jmp 0x5fd3b4
mov ebx, 7
push edi
call fcn.00578d00
mov eax, dword [ebp + 8]
add esp, 4
inc eax
cmp eax, 8
mov dword [ebp + 8], eax
jl 0x5fd358
mov al, byte [esi + 0x19]
test al, al
je 0x5fd4bc
mov edi, dword [ebp + 0x14]
mov edx, dword [ebp + 0x10]
push edi
push edx
push str.SELECT__FROM___w_.__w_rowid__WHERE_rowid_1
call fcn.0057aa30
add esp, 0xc
mov dword [esi + 0x40], eax
test eax, eax
jne 0x5fd3fe
mov ebx, 7
pop edi
mov eax, ebx
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp + 0xc]
push eax
call fcn.0057a960
mov ecx, dword [ebp + 0x10]
push edi
mov ebx, eax
push ecx
push str.UPDATE___w_.__w_rowid_SET
push ebx
call fcn.0057ab60
mov al, byte [esi + 0x19]
add esp, 0x14
xor edi, edi
test al, al
jbe 0x5fd475
test edi, edi
je 0x5fd439
push 1
push 0x75484c
push ebx
call fcn.0057a720
add esp, 0xc
xor edx, edx
mov dl, byte [esi + 0x1a]
cmp edi, edx
jge 0x5fd458
lea eax, [edi + 2]
push edi
push eax
push edi
push str.a_dcoalesce___d_a_d_
push ebx
call fcn.0057ab60
add esp, 0x14
jmp 0x5fd46b
lea ecx, [edi + 2]
push ecx
push edi
push str.a_d__d
push ebx
call fcn.0057ab60
add esp, 0x10
xor edx, edx
inc edi
mov dl, byte [esi + 0x19]
cmp edi, edx
jl 0x5fd425
push str._WHERE_rowid_1
push ebx
call fcn.0057ab60
push ebx
call fcn.0057a7e0
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x5fd49d
mov ebx, 7
pop edi
mov eax, ebx
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp + 0xc]
add esi, 0x70
push 0
push esi
push 5
push 0xffffffffffffffff
push edi
push eax
call fcn.005aea50
push edi
mov ebx, eax
call fcn.00578d00
add esp, 0x1c
pop edi
mov eax, ebx
pop esi
pop ebx
mov esp, ebp
pop ebp
ret