Function at 0x100800c0
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x14c
mov eax, dword [0x102d4008]
xor eax, esp
mov dword [esp + 0x148], eax
push ebx
mov ebx, dword [ebp + 8]
mov eax, ecx
push esi
push edi
xor edi, edi
mov dword [esp + 0x20], eax
mov ecx, dword [eax + 0x34]
mov dword [esp + 0x6c], ebx
mov dword [esp + 0x2c], 0
mov dword [esp + 0x14], edi
mov dword [esp + 0x70], edi
mov dword [esp + 0x14c], edi
mov byte [esp + 0x150], 0
mov dword [esp + 0xd0], edi
mov dword [esp + 0xd8], edi
mov dword [esp + 0x38], ecx
test ebx, ebx
jne 0x1008013c
lea eax, [ebx + 7]
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x148]
xor ecx, esp
call fcn.1010f56f
mov esp, ebp
pop ebp
ret
movzx ebx, word [eax + 0x18]
movzx ecx, byte [eax + 0xc]
lea esi, [ecx + ebx]
cmp esi, 2
jae 0x10080150
xor edx, edx
jmp 0x1008016d
test edx, edx
je 0x10080163
cmp edx, esi
jne 0x10080162
mov eax, dword [ebp + 0x10]
lea edx, [eax - 2]
add edx, esi
jmp 0x10080166
dec edx
mov eax, dword [ebp + 0x10]
mov esi, 2
sub esi, eax
lea eax, [esi + 1]
mov dword [esp + 0x50], edx
mov dword [esp + 0x3c], eax
mov eax, edx
sub eax, ecx
mov dword [esp + 0x58], esi
lea ecx, [eax + esi]
cmp ecx, ebx
jne 0x10080199
mov eax, dword [esp + 0x20]
movzx ecx, byte [eax + 9]
mov eax, dword [eax + 0x38]
add ecx, 8
add ecx, eax
jmp 0x100801b4
mov edx, dword [esp + 0x20]
mov eax, dword [edx + 0x40]
mov ax, word [eax + ecx*2]
mov ch, al
mov cl, ah
movzx eax, word [edx + 0x1a]
movzx ecx, cx
and ecx, eax
add ecx, dword [edx + 0x38]
mov edx, dword [ecx]
lea ebx, [esp + 0x12c]
push 0
bswap edx
mov dword [esp + 0x50], ecx
lea ebx, [ebx + esi*4]
mov ecx, dword [esp + 0x3c]
push 0
push ebx
mov dword [esp + 0x68], edx
mov dword [esp + 0x40], edx
call fcn.1007a0f0
add esp, 0xc
mov dword [esp + 0x10], eax
mov dword [esp + 0x18], eax
test eax, eax
jne 0x1008037d
nop
mov ecx, dword [ebx]
mov edx, esi
mov dword [esp + 0x48], edx
cmp dword [ecx + 0x14], 0
jge 0x10080215
call fcn.10079be0
mov dword [esp + 0x10], eax
mov dword [esp + 0x18], eax
test eax, eax
jne 0x1008040e
mov edx, esi
mov eax, esi
dec esi
test eax, eax
je 0x10080448
mov eax, dword [esp + 0x20]
mov bl, byte [eax + 0xc]
test bl, bl
je 0x10080275
movzx ecx, word [eax + 0x1c]
mov eax, dword [esp + 0x50]
add eax, esi
cmp eax, ecx
jne 0x10080275
mov edx, dword [esp + 0x20]
lea ebx, [esi*4]
mov eax, dword [edx + 0x24]
push eax
mov dword [esp + ebx + 0x64], eax
push edx
mov ecx, dword [eax]
mov eax, dword [edx + 0x4c]
bswap ecx
mov dword [esp + 0x64], ecx
mov dword [esp + 0x3c], ecx
call eax
movzx eax, ax
mov dword [esp + ebx + 0x84], eax
mov eax, dword [esp + 0x28]
mov byte [eax + 0xc], 0
jmp 0x1008034c
movzx eax, bl
mov ecx, edx
mov ebx, dword [esp + 0x20]
sub ecx, eax
add ecx, dword [esp + 0x50]
mov eax, dword [ebx + 0x40]
mov ax, word [eax + ecx*2 - 2]
mov ch, al
mov cl, ah
movzx eax, word [ebx + 0x1a]
movzx ecx, cx
and ecx, eax
mov eax, dword [ebx + 0x38]
add eax, ecx
lea ebx, [edx*4 - 4]
push eax
mov dword [esp + 0x20], eax
mov dword [esp + ebx + 0x64], eax
mov ecx, dword [eax]
mov eax, dword [esp + 0x24]
bswap ecx
push eax
mov dword [esp + 0x64], ecx
mov eax, dword [eax + 0x4c]
mov dword [esp + 0x3c], ecx
call eax
mov ecx, dword [esp + 0x40]
add esp, 8
movzx eax, ax
mov dword [esp + 0x24], eax
mov dword [esp + ebx + 0x7c], eax
test byte [ecx + 0x18], 0xc
je 0x10080328
mov edi, dword [esp + 0x20]
mov ecx, dword [esp + 0x1c]
mov edx, ecx
sub edx, dword [edi + 0x38]
mov edi, dword [esp + 0x38]
add eax, edx
cmp eax, dword [edi + 0x28]
mov edi, 0
jg 0x1008041a
push dword [esp + 0x24]
mov eax, dword [esp + 0x70]
push ecx
add eax, edx
push eax
call sub.VCRUNTIME140.dll_memcpy
mov ecx, dword [esp + 0x2c]
add esp, 0xc
mov eax, dword [esp + 0x6c]
sub eax, dword [ecx + 0x38]
add eax, dword [esp + 0x1c]
mov dword [esp + ebx + 0x60], eax
mov eax, dword [esp + 0x24]
mov edx, dword [esp + 0x50]
lea ecx, [esp + 0x18]
push ecx
mov ecx, dword [esp + 0x4c]
dec edx
push eax
mov eax, dword [esp + 0x28]
movzx eax, byte [eax + 0xc]
sub ecx, eax
add edx, ecx
mov ecx, dword [esp + 0x28]
call fcn.1007f2e0
mov edx, dword [esp + 0x64]
lea eax, [esp + 0x134]
mov ecx, dword [esp + 0x40]
add esp, 8
add ebx, eax
push 0
push 0
push ebx
call fcn.1007a0f0
add esp, 0xc
mov dword [esp + 0x10], eax
mov dword [esp + 0x18], eax
test eax, eax
je 0x100801f0
lea eax, [esi*4 + 4]
push eax
lea eax, [esp + 0x130]
push 0
push eax
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
xor ebx, ebx
cmp dword [esp + 0x3c], ebx
jle 0x10081483
nop dword [eax]
nop word [eax + eax]
mov edx, dword [esp + ebx*4 + 0x12c]
test edx, edx
je 0x10081478
mov edx, dword [edx + 0x48]
test byte [edx + 0x1c], 0x20
je 0x10081471
mov eax, dword [edx + 0x14]
dec dword [eax + 0x78]
mov ecx, dword [eax + 0x88]
mov dword [edx + 0x10], ecx
mov esi, dword [eax + 0x3c]
mov dword [eax + 0x88], edx
push dword [edx + 4]
mov ecx, dword [edx + 0x18]
mov eax, dword [eax + 0x98]
dec ecx
mov edi, dword [esi]
cdq
push edx
push eax
push 0
push ecx
call fcn.10181160
push edx
push eax
mov eax, dword [edi + 0x48]
push esi
call eax
add esp, 0x10
jmp 0x10081478
lea eax, [esi*4]
jmp 0x10080384
push 0x102b62b4
push 0x126a3
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call sym.BasicSQLite.dll_sqlite3_log
add esp, 0x14
mov dword [esp + 0x10], 0xb
lea eax, [ebx + 4]
jmp 0x10080384
mov eax, dword [esp + 0x38]
mov esi, dword [eax + 0x24]
mov eax, 0xaaaaaaab
lea ecx, [esi - 8]
mul ecx
mov ebx, edx
shr ebx, 2
add ebx, 4
imul ebx, dword [esp + 0x3c]
add ebx, 3
and ebx, 0xfffffffc
lea eax, [ebx + ebx*2]
add eax, eax
mov dword [esp + 0x28], eax
add eax, esi
cdq
push edx
push eax
call fcn.10065db0
mov esi, eax
add esp, 8
mov dword [esp + 0xd8], esi
test esi, esi
jne 0x1008049c
mov dword [esp + 0x10], 7
jmp 0x10080397
mov ecx, dword [esp + 0x12c]
lea eax, [esi + ebx*4]
mov dword [esp + 0xdc], eax
mov eax, dword [esp + 0x28]
add eax, esi
mov dword [esp + 0xd4], ecx
mov dword [esp + 0x28], eax
movzx eax, byte [ecx + 8]
shl ax, 2
movzx eax, ax
mov dword [esp + 0x48], eax
mov al, byte [ecx + 3]
mov byte [esp + 0xf], al
movzx eax, al
mov dword [esp + 0xa4], eax
xor eax, eax
mov dword [esp + 0x44], eax
cmp dword [esp + 0x3c], eax
jle 0x1008072f
nop
shl eax, 2
mov dword [esp + 0x54], eax
mov ebx, dword [esp + eax + 0x12c]
mov dword [esp + 0x30], ebx
movzx eax, word [ebx + 0x18]
mov edx, dword [ebx + 0x38]
movzx esi, word [ebx + 0x12]
mov dword [esp + 0x1c], eax
add esi, edx
movzx eax, word [ebx + 0x1a]
mov ecx, eax
mov dword [esp + 0x78], eax
mov eax, dword [esp + 0x12c]
mov dword [esp + 0x74], ecx
mov dword [esp + 0x24], edx
mov dword [esp + 0x40], esi
mov ecx, dword [eax + 0x38]
mov al, byte [edx]
cmp al, byte [ecx]
jne 0x100808a9
movzx eax, byte [ebx + 0xc]
add eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0xdc]
add eax, eax
push eax
mov eax, dword [esp + 0xd4]
push 0
lea eax, [ecx + eax*2]
push eax
call sub.VCRUNTIME140.dll_memset
mov al, byte [ebx + 0xc]
add esp, 0xc
test al, al
je 0x10080606
movzx edx, word [ebx + 0x1c]
cmp dword [esp + 0x1c], edx
jb 0x1008087e
test edx, edx
je 0x100805ce
mov edi, dword [esp + 0xd0]
mov ebx, dword [esp + 0x24]
nop dword [eax]
mov ax, word [esi]
add esi, 2
mov ch, al
mov cl, ah
mov eax, dword [esp + 0x74]
movzx ecx, cx
movzx eax, ax
and ecx, eax
mov eax, dword [esp + 0xd8]
add ecx, ebx
mov dword [eax + edi*4], ecx
inc edi
sub edx, 1
jne 0x10080590
mov ebx, dword [esp + 0x30]
mov dword [esp + 0xd0], edi
mov edi, dword [esp + 0x14]
mov dword [esp + 0x40], esi
mov al, byte [ebx + 0xc]
xor edx, edx
test al, al
je 0x10080606
mov edi, dword [esp + 0xd0]
lea ecx, [ebx + 0x24]
mov esi, dword [esp + 0xd8]
mov eax, dword [ecx]
lea ecx, [ecx + 4]
mov dword [esi + edi*4], eax
inc edx
movzx eax, byte [ebx + 0xc]
inc edi
cmp edx, eax
jl 0x100805e5
mov esi, dword [esp + 0x40]
mov dword [esp + 0xd0], edi
mov edi, dword [esp + 0x14]
movzx eax, word [ebx + 0x12]
xor edx, edx
movzx ecx, word [ebx + 0x18]
add eax, dword [esp + 0x24]
lea eax, [eax + ecx*2]
xor ecx, ecx
mov ebx, eax
sub ebx, esi
inc ebx
shr ebx, 1
cmp esi, eax
cmova ebx, ecx
test ebx, ebx
je 0x10080665
mov edi, dword [esp + 0xd0]
mov ax, word [esi]
lea esi, [esi + 2]
mov ch, al
inc edx
mov cl, ah
mov eax, dword [esp + 0x78]
movzx ecx, cx
movzx eax, ax
and ecx, eax
mov eax, dword [esp + 0xd8]
add ecx, dword [esp + 0x24]
mov dword [eax + edi*4], ecx
inc edi
cmp edx, ebx
jb 0x10080630
mov dword [esp + 0xd0], edi
mov edi, dword [esp + 0x14]
mov edx, dword [esp + 0x54]
mov eax, dword [esp + 0x44]
mov ebx, dword [esp + 0xd0]
mov dword [esp + edx + 0xbc], ebx
cmp eax, dword [esp + 0x58]
jge 0x10080720
cmp byte [esp + 0xf], 0
jne 0x10080720
movzx eax, word [esp + edx + 0x7c]
mov ecx, dword [esp + 0xdc]
mov esi, dword [esp + 0x28]
push eax
push dword [esp + edx + 0x64]
add esi, edi
mov word [ecx + ebx*2], ax
add edi, eax
push esi
mov dword [esp + 0x20], edi
call sub.VCRUNTIME140.dll_memcpy
mov ecx, dword [esp + 0x54]
add esp, 0xc
mov edx, dword [esp + 0xdc]
movzx eax, cx
add eax, esi
mov esi, dword [esp + 0xd8]
mov dword [esi + ebx*4], eax
mov eax, dword [esp + 0x30]
sub word [edx + ebx*2], cx
cmp byte [eax + 8], 0
jne 0x100806ef
mov eax, dword [eax + 0x38]
mov ecx, dword [esi + ebx*4]
mov eax, dword [eax + 8]
mov dword [ecx], eax
jmp 0x10080714
cmp word [edx + ebx*2], 4
jae 0x10080714
mov eax, dword [esp + 0x28]
nop word [eax + eax]
mov byte [eax + edi], 0
inc edi
inc word [edx + ebx*2]
cmp word [edx + ebx*2], 4
jb 0x10080700
mov dword [esp + 0x14], edi
mov eax, dword [esp + 0x44]
inc ebx
mov dword [esp + 0xd0], ebx
inc eax
mov dword [esp + 0x44], eax
cmp eax, dword [esp + 0x3c]
jl 0x100804f0
mov eax, dword [esp + 0x48]
xor ecx, ecx
movzx edi, ax
xor ebx, ebx
mov eax, dword [esp + 0x38]
mov dword [esp + 0x14], ecx
mov dword [esp + 0x30], ebx
mov eax, dword [eax + 0x28]
add eax, 0xfffffff4
add edi, eax
mov eax, dword [esp + 0x3c]
mov dword [esp + 0x44], edi
test eax, eax
jle 0x1008083a
nop
mov esi, dword [esp + ebx*4 + 0x12c]
mov edx, dword [esp + ebx*4 + 0xbc]
mov dword [esp + 0x54], edx
mov eax, dword [esi + 0x3c]
mov dword [esp + ecx*4 + 0xe0], eax
mov dword [esp + ecx*4 + 0xf8], edx
test ecx, ecx
je 0x10080795
cmp edx, dword [esp + ecx*4 + 0xf4]
jne 0x10080795
dec ecx
mov dword [esp + 0x14], ecx
cmp byte [esp + 0xf], 0
jne 0x100807b9
mov eax, dword [esp + 0x20]
inc ecx
mov dword [esp + 0x14], ecx
mov eax, dword [eax + 0x3c]
mov dword [esp + ecx*4 + 0xe0], eax
lea eax, [edx + 1]
mov dword [esp + ecx*4 + 0xf8], eax
sub edi, dword [esi + 0x14]
lea eax, [esp + 0x7c]
cmp byte [esi + 0xc], 0
lea eax, [eax + ebx*4]
mov dword [esp + 0x58], eax
mov dword [eax], edi
mov dword [esp + 0x28], 0
jbe 0x10080819
lea ebx, [esi + 0x24]
nop word [eax + eax]
push dword [ebx]
mov eax, dword [esi + 0x4c]
push esi
call eax
mov ecx, dword [esp + 0x30]
lea ebx, [ebx + 4]
movzx eax, ax
inc ecx
add eax, 2
mov dword [esp + 0x30], ecx
add edi, eax
add esp, 8
movzx eax, byte [esi + 0xc]
cmp ecx, eax
jl 0x100807e0
mov eax, dword [esp + 0x58]
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x54]
mov ebx, dword [esp + 0x30]
mov dword [eax], edi
mov eax, dword [esp + 0x3c]
inc ecx
mov edi, dword [esp + 0x44]
mov dword [esp + ebx*4 + 0x90], edx
inc ebx
mov dword [esp + 0x30], ebx
mov dword [esp + 0x14], ecx
cmp ebx, eax
jl 0x10080760
mov ebx, dword [esp + 0xd0]
mov edi, eax
mov dword [esp + 0x40], edi
mov dword [esp + 0x1c], 0
test eax, eax
jle 0x10080a83
mov edx, 1
xor ecx, ecx
mov dword [esp + 0x14], edx
mov dword [esp + 0x24], ecx
lea eax, [esp + 0x7c]
add eax, ecx
mov dword [esp + 0x58], eax
mov esi, dword [eax]
cmp esi, dword [esp + 0x44]
jle 0x100809b2
jmp 0x100808da
push 0x102b62b4
push 0x126fe
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call sym.BasicSQLite.dll_sqlite3_log
add esp, 0x14
mov dword [esp + 0x10], 0xb
jmp 0x10081454
push 0x102b62b4
push 0x126e6
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call sym.BasicSQLite.dll_sqlite3_log
add esp, 0x14
mov dword [esp + 0x10], 0xb
jmp 0x10081454
lea eax, [esp + 0x7c]
add eax, ecx
cmp edx, edi
jl 0x10080909
inc edx
mov dword [esp + 0x40], edx
cmp edx, 5
jg 0x10080b33
mov ebx, dword [esp + 0xd0]
mov dword [esp + ecx + 0x80], 0
mov esi, dword [eax]
mov dword [esp + ecx + 0x94], ebx
jmp 0x10080910
mov ebx, dword [esp + 0xd0]
mov edi, dword [esp + ecx + 0x90]
mov edx, dword [esp + 0xdc]
lea ecx, [edi - 1]
mov dword [esp + 0x54], ecx
movzx eax, word [edx + ecx*2]
test ax, ax
jne 0x10080946
mov edx, ecx
lea ecx, [esp + 0xd0]
call fcn.1007f680
mov edx, dword [esp + 0xdc]
movzx eax, ax
mov ecx, dword [esp + 0x58]
movzx eax, ax
add eax, 2
sub esi, eax
cmp byte [esp + 0xf], 0
mov dword [ecx], esi
jne 0x10080983
cmp edi, ebx
jge 0x10080981
movzx eax, word [edx + edi*2]
test ax, ax
jne 0x10080979
mov edx, edi
lea ecx, [esp + 0xd0]
call fcn.1007f680
movzx eax, ax
movzx eax, ax
add eax, 2
jmp 0x10080983
xor eax, eax
mov ecx, dword [esp + 0x24]
mov edx, dword [esp + 0x14]
mov edi, dword [esp + 0x40]
add dword [esp + ecx + 0x80], eax
mov eax, dword [esp + 0x54]
mov dword [esp + ecx + 0x90], eax
cmp esi, dword [esp + 0x44]
jg 0x100808d4
mov ebx, dword [esp + 0xd0]
mov edi, dword [esp + ecx + 0x90]
cmp edi, ebx
jge 0x10080a60
mov edx, dword [esp + 0xdc]
nop dword [eax + eax]
movzx eax, word [edx + edi*2]
test ax, ax
jne 0x100809f5
mov edx, edi
lea ecx, [esp + 0xd0]
call fcn.1007f680
mov ecx, dword [esp + 0x24]
mov edx, dword [esp + 0xdc]
movzx eax, ax
movzx eax, ax
add eax, 2
add esi, eax
cmp esi, dword [esp + 0x44]
jg 0x10080b08
inc edi
mov dword [esp + ecx + 0x7c], esi
cmp byte [esp + 0xf], 0
mov dword [esp + ecx + 0x90], edi
jne 0x10080a4d
cmp edi, ebx
jge 0x10080a4b
movzx eax, word [edx + edi*2]
test ax, ax
jne 0x10080a3f
mov edx, edi
lea ecx, [esp + 0xd0]
call fcn.1007f680
mov edx, dword [esp + 0xdc]
movzx eax, ax
mov ecx, dword [esp + 0x24]
movzx eax, ax
add eax, 2
jmp 0x10080a4d
xor eax, eax
sub dword [esp + ecx + 0x80], eax
cmp edi, ebx
jl 0x100809d0
mov edx, dword [esp + 0x14]
mov edi, edx
mov dword [esp + 0x40], edi
mov eax, dword [esp + 0x1c]
add ecx, 4
inc eax
mov dword [esp + 0x24], ecx
inc edx
mov dword [esp + 0x1c], eax
mov dword [esp + 0x14], edx
cmp eax, edi
jl 0x10080866
lea eax, [edi - 1]
mov ecx, eax
mov dword [esp + 0x14], eax
test ecx, ecx
jle 0x10080c8e
shl ecx, 2
lea eax, [esp + 0x7c]
add eax, ecx
mov dword [esp + 0x58], ecx
mov dword [esp + 0x74], eax
mov edi, dword [eax]
lea eax, [esp + ecx + 0x78]
mov dword [esp + 0x60], eax
mov eax, dword [eax]
mov dword [esp + 0x24], eax
lea eax, [esp + 0x90]
sub eax, 4
mov dword [esp + 0x30], eax
mov eax, dword [eax + ecx]
mov ecx, dword [esp + 0xdc]
mov dword [esp + 0x28], eax
lea esi, [eax - 1]
mov edx, esi
sub edx, dword [esp + 0xa4]
inc edx
cmp word [ecx + edx*2], 0
lea eax, [ecx + edx*2]
mov dword [esp + 0x1c], eax
jne 0x10080aff
lea ecx, [esp + 0xd0]
call fcn.1007f680
mov ecx, dword [esp + 0xdc]
mov ebx, dword [esp + 0x1c]
jmp 0x10080b97
cmp edi, ebx
jge 0x10080a5c
cmp dword [esp + 0x1c], 0
jle 0x10080b20
mov eax, dword [esp + ecx + 0x8c]
jmp 0x10080b22
xor eax, eax
cmp edi, eax
jle 0x10080b5e
mov edx, dword [esp + 0x14]
mov edi, dword [esp + 0x40]
jmp 0x10080a66
push 0x102b62b4
push 0x12763
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call sym.BasicSQLite.dll_sqlite3_log
add esp, 0x14
mov dword [esp + 0x10], 0xb
jmp 0x10081454
push 0x102b62b4
push 0x12784
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call sym.BasicSQLite.dll_sqlite3_log
add esp, 0x14
mov dword [esp + 0x10], 0xb
jmp 0x10081454
mov ecx, dword [esp + 0xdc]
cmp word [ecx + esi*2], 0
mov dword [esp + 0x78], esi
mov dword [esp + 0x54], esi
jne 0x10080bb4
mov edx, esi
lea ecx, [esp + 0xd0]
call fcn.1007f680
test edi, edi
je 0x10080c01
cmp dword [ebp + 0x10], 0
mov eax, dword [esp + 0x28]
mov edx, eax
jne 0x10080c46
mov ecx, dword [esp + 0x40]
mov eax, 2
mov ebx, dword [esp + 0x1c]
dec ecx
cmp dword [esp + 0x14], ecx
mov ecx, 0
cmove eax, ecx
mov ecx, dword [esp + 0x24]
sub ecx, eax
mov eax, dword [esp + 0xdc]
movzx eax, word [eax + esi*2]
sub ecx, eax
movzx eax, word [ebx]
add eax, 2
add eax, edi
cmp eax, ecx
jg 0x10080c46
movzx eax, word [ebx]
mov ecx, 0xfffffffe
mov edx, dword [esp + 0x78]
add eax, 2
add edi, eax
sub ebx, 2
mov eax, dword [esp + 0xdc]
mov dword [esp + 0x1c], ebx
movzx eax, word [eax + esi*2]
sub ecx, eax
mov eax, dword [esp + 0x58]
add dword [esp + 0x24], ecx
mov ecx, dword [esp + 0x30]
mov dword [ecx + eax], esi
sub esi, 1
mov eax, dword [esp + 0x54]
mov dword [esp + 0x28], eax
jns 0x10080b90
mov eax, dword [esp + 0x74]
mov ecx, dword [esp + 0x60]
mov ebx, dword [esp + 0xd0]
mov dword [eax], edi
mov eax, dword [esp + 0x24]
mov dword [ecx], eax
mov ecx, dword [esp + 0x14]
cmp ecx, 1
jle 0x10080c77
mov esi, dword [esp + 0x30]
lea eax, [ecx*4]
mov eax, dword [eax + esi - 4]
jmp 0x10080c79
xor eax, eax
cmp edx, eax
jle 0x10080cf8
dec ecx
mov dword [esp + 0x14], ecx
test ecx, ecx
jg 0x10080a94
mov edi, dword [esp + 0x40]
mov eax, dword [esp + 0x12c]
xor esi, esi
mov eax, dword [eax + 0x38]
movzx eax, byte [eax]
mov dword [esp + 0x30], eax
lea eax, [esi + 1]
test edi, edi
jle 0x10080e06
nop dword [eax]
cmp esi, dword [esp + 0x3c]
jge 0x10080d65
mov eax, dword [esp + esi*4 + 0x12c]
mov dword [esp + esi*4 + 0x138], eax
mov dword [esp + esi*4 + 0x12c], 0
mov dword [esp + 0x28], eax
mov ecx, dword [eax + 0x48]
test byte [ecx + 0x1c], 4
mov edx, dword [ecx + 0x14]
je 0x10080d27
mov eax, dword [edx + 0x18]
cmp eax, dword [ecx + 0x18]
jb 0x10080d27
cmp dword [edx + 0x60], 0
je 0x10080d23
call fcn.10072f40
jmp 0x10080d4c
push 0x102b62b4
push 0x127ae
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call sym.BasicSQLite.dll_sqlite3_log
add esp, 0x14
mov dword [esp + 0x10], 0xb
jmp 0x10081454
xor eax, eax
jmp 0x10080d4c
mov eax, dword [edx + 0x28]
mov dword [esp + 0x10], eax
test eax, eax
jne 0x10080d50
mov eax, dword [edx + 0x94]
cmp eax, dword [edx + 0x98]
jbe 0x10080d47
call fcn.10074850
jmp 0x10080d4c
call fcn.10074620
mov dword [esp + 0x10], eax
inc dword [esp + 0x2c]
mov dword [esp + 0x18], eax
test eax, eax
jne 0x10081454
jmp 0x10080df8
cmp dword [ebp + 0x10], 0
lea edx, [esp + 0x28]
mov ecx, dword [esp + 0x5c]
cmovne ecx, eax
lea eax, [esp + 0x34]
push 0
push ecx
mov ecx, dword [esp + 0x40]
push eax
call fcn.1007e060
add esp, 0xc
mov dword [esp + 0x10], eax
mov dword [esp + 0x18], eax
test eax, eax
jne 0x10081454
mov edi, dword [esp + 0x28]
mov ecx, edi
mov edx, dword [esp + 0x30]
call fcn.10079f20
mov ecx, dword [esp + 0x38]
inc dword [esp + 0x2c]
mov dword [esp + esi*4 + 0x138], edi
mov dword [esp + esi*4 + 0xbc], ebx
cmp byte [ecx + 0x11], 0
je 0x10080dec
mov edx, dword [edi + 4]
lea eax, [esp + 0x18]
push eax
mov eax, dword [esp + 0x24]
push dword [eax + 4]
push 5
call fcn.10078be0
mov eax, dword [esp + 0x24]
add esp, 0xc
mov dword [esp + 0x10], eax
test eax, eax
jne 0x10081454
mov edx, dword [esp + 0x34]
mov edi, dword [esp + 0x40]
mov dword [esp + 0x5c], edx
inc esi
mov eax, 1
cmp esi, edi
jl 0x10080cb0
mov ebx, dword [esp + 0x2c]
xor ecx, ecx
test ebx, ebx
jle 0x10080e57
mov eax, dword [esp + ecx*4 + 0x138]
mov edx, dword [eax + 4]
mov eax, dword [eax + 0x48]
mov dword [esp + ecx*4 + 0x110], edx
mov dword [esp + ecx*4 + 0xa8], edx
mov ax, word [eax + 0x1c]
mov word [esp + ecx*2 + 0x60], ax
xor eax, eax
test ecx, ecx
jle 0x10080e52
nop word [eax + eax]
cmp dword [esp + eax*4 + 0x110], edx
je 0x10080fb4
inc eax
cmp eax, ecx
jl 0x10080e40
inc ecx
cmp ecx, ebx
jl 0x10080e10
xor edi, edi
test ebx, ebx
jle 0x10080ef2
xor esi, esi
lea edx, [esi + 1]
cmp ebx, edx
jle 0x10080e8a
nop word [eax + eax]
mov eax, dword [esp + edx*4 + 0xa8]
mov ecx, edx
cmp eax, dword [esp + esi*4 + 0xa8]
cmovae ecx, esi
inc edx
mov esi, ecx
cmp edx, ebx
jl 0x10080e70
mov ebx, dword [esp + esi*4 + 0xa8]
mov dword [esp + esi*4 + 0xa8], 0xffffffff
cmp esi, edi
je 0x10080ee5
jle 0x10080ec1
mov eax, dword [esp + 0x38]
mov edx, dword [eax + 0x30]
mov eax, dword [esp + esi*4 + 0x138]
inc edx
add edx, esi
mov ecx, dword [eax + 0x48]
xor eax, eax
mov word [ecx + 0x1c], ax
call fcn.1006ec60
mov eax, dword [esp + edi*4 + 0x138]
mov edx, ebx
mov ecx, dword [eax + 0x48]
mov ax, word [esp + esi*2 + 0x60]
mov word [ecx + 0x1c], ax
call fcn.1006ec60
mov eax, dword [esp + edi*4 + 0x138]
mov dword [eax + 4], ebx
mov ebx, dword [esp + 0x2c]
inc edi
cmp edi, ebx
jl 0x10080e61
test byte [esp + 0x30], 8
mov eax, dword [esp + ebx*4 + 0x134]
mov ecx, dword [esp + 0x4c]
mov eax, dword [eax + 4]
bswap eax
mov dword [ecx], eax
jne 0x10080f3b
mov ecx, dword [esp + 0x3c]
cmp ecx, ebx
je 0x10080f3b
lea edx, [esp + 0x12c]
lea eax, [esp + 0x138]
cmovge eax, edx
mov eax, dword [eax + ecx*4 - 4]
mov edx, dword [eax + 0x38]
mov eax, dword [esp + ebx*4 + 0x134]
mov ecx, dword [eax + 0x38]
mov eax, dword [edx + 8]
mov dword [ecx + 8], eax
mov eax, dword [esp + 0x38]
cmp byte [eax + 0x11], 0
je 0x100810fe
mov esi, dword [esp + 0x138]
xor edi, edi
xor ebx, ebx
mov dword [esp + 0x4c], 0
movzx eax, byte [esi + 0xc]
movzx edx, word [esi + 0x18]
add edx, eax
mov eax, dword [esp + 0xd0]
mov dword [esp + 0x1c], edx
test eax, eax
jle 0x10081107
mov dword [esp + 0x28], ebx
mov dword [esp + 0x34], esi
mov ecx, dword [esp + 0xd8]
mov ecx, dword [ecx + ebx*4]
mov dword [esp + 0x30], ecx
cmp ebx, edx
jne 0x10081005
xor eax, eax
cmp byte [esp + 0xf], al
sete al
mov dword [esp + 0x60], eax
inc edi
cmp edi, dword [esp + 0x2c]
jge 0x10080fdf
mov esi, dword [esp + edi*4 + 0x138]
jmp 0x10080fe6
push 0x102b62b4
push 0x127f8
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call sym.BasicSQLite.dll_sqlite3_log
add esp, 0x14
mov dword [esp + 0x10], 0xb
jmp 0x10081454
mov esi, dword [esp + edi*4 + 0x12c]
movzx eax, word [esi + 0x18]
add eax, dword [esp + 0x60]
movzx ecx, byte [esi + 0xc]
add ecx, eax
add edx, ecx
cmp ebx, edx
je 0x10080fa4
mov eax, dword [esp + 0xd0]
mov dword [esp + 0x1c], edx
mov ecx, dword [esp + 0x28]
cmp ebx, dword [esp + ecx + 0x90]
mov ecx, dword [esp + 0x30]
jne 0x10081040
mov edx, dword [esp + 0x4c]
inc edx
mov dword [esp + 0x4c], edx
shl edx, 2
cmp byte [esp + 0xf], 0
mov dword [esp + 0x28], edx
mov edx, dword [esp + edx + 0x138]
mov dword [esp + 0x34], edx
mov edx, dword [esp + 0x1c]
je 0x100810f1
cmp edi, dword [esp + 0x2c]
jge 0x10081064
mov eax, dword [esp + 0x34]
mov eax, dword [eax + 4]
cmp eax, dword [esp + edi*4 + 0x110]
jne 0x10081064
cmp ecx, dword [esi + 0x38]
jb 0x10081064
cmp ecx, dword [esi + 0x3c]
jb 0x100810ea
cmp word [esp + 0x48], 0
jne 0x10081092
mov edx, dword [ecx]
lea eax, [esp + 0x18]
mov ecx, dword [esp + 0x38]
push eax
mov eax, dword [esp + 0x38]
bswap edx
push dword [eax + 4]
push 5
call fcn.10078be0
mov eax, dword [esp + 0x24]
add esp, 0xc
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0xdc]
movzx eax, word [eax + ebx*2]
test ax, ax
jne 0x100810b3
mov edx, ebx
lea ecx, [esp + 0xd0]
call fcn.1007f680
movzx eax, ax
mov ecx, dword [esp + 0x34]
cmp ax, word [ecx + 0x10]
jbe 0x100810da
lea eax, [esp + 0x18]
mov edx, esi
push eax
push dword [esp + 0x34]
call fcn.10079140
mov eax, dword [esp + 0x20]
add esp, 8
mov dword [esp + 0x10], eax
jmp 0x100810de
mov eax, dword [esp + 0x10]
test eax, eax
jne 0x10081454
mov edx, dword [esp + 0x1c]
mov eax, dword [esp + 0xd0]
inc ebx
cmp ebx, eax
jl 0x10080f81
mov ebx, dword [esp + 0x2c]
mov esi, dword [esp + 0x138]
jmp 0x1008110b
mov ebx, dword [esp + 0x2c]
lea eax, [ebx - 1]
xor edi, edi
test eax, eax
jle 0x1008126b
nop dword [eax + eax]
mov eax, dword [esp + edi*4 + 0x90]
mov edx, dword [esp + 0xd8]
mov esi, dword [edx + eax*4]
lea edx, [edx + eax*4]
mov ecx, dword [esp + edi*4 + 0x138]
mov ebx, dword [esp + 0x70]
add ebx, dword [esp + 0x6c]
mov dword [esp + 0x60], edx
mov edx, dword [esp + 0xdc]
mov dword [esp + 0x34], ecx
mov ecx, dword [esp + 0x48]
movzx eax, word [edx + eax*2]
movzx edx, cx
mov ecx, dword [esp + 0x34]
add edx, eax
cmp byte [ecx + 8], 0
jne 0x10081176
mov ecx, dword [ecx + 0x38]
mov eax, dword [esi]
mov dword [ecx + 8], eax
jmp 0x1008121e
cmp byte [esp + 0xf], 0
je 0x10081205
lea eax, [esp + 0x110]
push eax
mov eax, dword [esp + 0x64]
push dword [eax - 4]
mov eax, dword [ecx + 0x50]
push ecx
call eax
mov edx, dword [esp + 0x120]
add esp, 0xc
mov ecx, dword [esp + 0x110]
mov esi, ebx
test edx, edx
ja 0x100811f1
jb 0x100811b4
cmp ecx, 0x7f
ja 0x100811c6
mov eax, 1
and cl, 0x7f
mov byte [ebx + 4], cl
xor ebx, ebx
lea edx, [eax + 4]
jmp 0x1008121e
test edx, edx
ja 0x100811f1
jb 0x100811d4
cmp ecx, 0x3fff
ja 0x100811f1
mov eax, ecx
and cl, 0x7f
shrd eax, edx, 7
mov byte [ebx + 5], cl
or al, 0x80
mov byte [ebx + 4], al
mov eax, 2
xor ebx, ebx
lea edx, [eax + 4]
jmp 0x1008121e
push edx
push ecx
lea ecx, [ebx + 4]
call fcn.10069b30
add esp, 8
xor ebx, ebx
lea edx, [eax + 4]
jmp 0x1008121e
sub esi, 4
cmp eax, 4
jne 0x10081222
mov eax, dword [esp + 0x20]
push esi
push eax
mov eax, dword [eax + 0x4c]
call eax
add esp, 8
movzx edx, ax
mov ecx, dword [esp + 0x34]
add dword [esp + 0x70], edx
lea eax, [esp + 0x18]
push eax
push dword [ecx + 4]
mov ecx, dword [esp + 0x28]
push ebx
push edx
mov edx, dword [esp + 0x60]
push esi
lea edx, [edx + edi]
call fcn.1007f400
mov esi, dword [esp + 0x2c]
add esp, 0x14
mov dword [esp + 0x10], esi
test esi, esi
jne 0x10081454
mov ebx, dword [esp + 0x2c]
inc edi
lea eax, [ebx - 1]
cmp edi, eax
jl 0x10081120
mov esi, dword [esp + 0x138]
mov edi, 1
sub edi, ebx
mov dword [esp + 0x4c], edi
cmp edi, ebx
jge 0x1008135d
nop
mov eax, edi
lea ebx, [esp + 0x14c]
cdq
mov ecx, eax
xor ecx, edx
sub ecx, edx
add ebx, ecx
cmp byte [ebx], 0
jne 0x10081345
test edi, edi
jns 0x100812b3
mov eax, dword [esp + ecx*4 + 0xb8]
cmp eax, dword [esp + ecx*4 + 0x8c]
jl 0x10081345
test ecx, ecx
jne 0x100812c4
mov esi, dword [esp + 0x90]
xor edx, edx
xor eax, eax
jmp 0x100812fc
cmp ecx, dword [esp + 0x3c]
jge 0x100812dc
xor edx, edx
cmp byte [esp + 0xf], dl
sete dl
add edx, dword [esp + ecx*4 + 0xb8]
jmp 0x100812e3
mov edx, dword [esp + 0xd0]
mov esi, dword [esp + ecx*4 + 0x90]
xor eax, eax
cmp byte [esp + 0xf], al
sete al
add eax, dword [esp + ecx*4 + 0x8c]
sub esi, eax
lea edi, [ecx*4]
lea ecx, [esp + 0xd0]
push ecx
mov ecx, dword [esp + edi + 0x13c]
push esi
push eax
call fcn.1007fa90
add esp, 0xc
mov dword [esp + 0x10], eax
mov dword [esp + 0x18], eax
test eax, eax
jne 0x10081454
mov eax, dword [esp + edi + 0x138]
mov ecx, dword [esp + 0x44]
sub ecx, dword [esp + edi + 0x7c]
mov edi, dword [esp + 0x4c]
mov byte [ebx], 1
mov dword [eax + 0x14], ecx
mov ebx, dword [esp + 0x2c]
inc edi
mov dword [esp + 0x4c], edi
cmp edi, ebx
jl 0x10081280
mov esi, dword [esp + 0x138]
cmp dword [ebp + 0xc], 0
je 0x100813cc
mov edi, dword [esp + 0x20]
cmp word [edi + 0x18], 0
jne 0x100813cc
movzx eax, byte [edi + 9]
cmp eax, dword [esi + 0x14]
jg 0x100813cc
or edx, 0xffffffff
mov ecx, esi
call fcn.10079200
mov ecx, dword [esp + 0x138]
mov edx, edi
mov dword [esp + 0x18], eax
lea eax, [esp + 0x18]
push eax
call fcn.1007fff0
mov eax, dword [esp + 0x1c]
add esp, 4
mov dword [esp + 0x10], eax
test eax, eax
jne 0x1008141c
mov ecx, dword [esp + 0x138]
mov edx, ecx
push dword [ecx + 4]
mov ecx, dword [ecx + 0x34]
call fcn.1007e940
add esp, 4
mov dword [esp + 0x10], eax
jmp 0x1008141c
mov ecx, dword [esp + 0x38]
cmp byte [ecx + 0x11], 0
je 0x10081418
cmp word [esp + 0x48], 0
jne 0x10081418
xor esi, esi
test ebx, ebx
jle 0x10081418
mov eax, dword [esp + esi*4 + 0x138]
lea edx, [esp + 0x18]
push edx
push dword [eax + 4]
mov eax, dword [eax + 0x38]
push 5
mov edx, dword [eax + 8]
bswap edx
call fcn.10078be0
mov ecx, dword [esp + 0x44]
inc esi
add esp, 0xc
cmp esi, ebx
jl 0x100813e4
mov eax, dword [esp + 0x18]
mov dword [esp + 0x10], eax
jmp 0x1008141c
mov eax, dword [esp + 0x10]
mov edi, dword [esp + 0x3c]
mov esi, ebx
cmp ebx, edi
jge 0x10081454
nop word [eax + eax]
mov ecx, dword [esp + esi*4 + 0x12c]
test eax, eax
jne 0x1008144b
push dword [ecx + 4]
mov edx, ecx
mov ecx, dword [ecx + 0x34]
call fcn.1007e940
add esp, 4
inc esi
cmp esi, edi
jl 0x10081430
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0xd8]
test eax, eax
je 0x10080397
push eax
call sym.BasicSQLite.dll_sqlite3_free
add esp, 4
jmp 0x10080397
mov ecx, edx
call fcn.1006ea70
inc ebx
cmp ebx, dword [esp + 0x3c]
jl 0x100803b0
xor ebx, ebx
cmp dword [esp + 0x2c], ebx
jle 0x100814f1
nop
mov edx, dword [esp + ebx*4 + 0x138]
test edx, edx
je 0x100814ea
mov edx, dword [edx + 0x48]
test byte [edx + 0x1c], 0x20
je 0x100814e3
mov eax, dword [edx + 0x14]
dec dword [eax + 0x78]
mov ecx, dword [eax + 0x88]
mov dword [edx + 0x10], ecx
mov esi, dword [eax + 0x3c]
mov dword [eax + 0x88], edx
push dword [edx + 4]
mov ecx, dword [edx + 0x18]
mov eax, dword [eax + 0x98]
dec ecx
mov edi, dword [esi]
cdq
push edx
push eax
push 0
push ecx
call fcn.10181160
push edx
push eax
mov eax, dword [edi + 0x48]
push esi
call eax
add esp, 0x10
jmp 0x100814ea
mov ecx, edx
call fcn.1006ea70
inc ebx
cmp ebx, dword [esp + 0x2c]
jl 0x10081490
mov ecx, dword [esp + 0x154]
mov eax, dword [esp + 0x10]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.1010f56f
mov esp, ebp
pop ebp
ret