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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x154
mov eax, dword [0x101f62b4]
xor eax, esp
mov dword [esp + 0x150], eax
push ebx
xor ebx, ebx
mov dword [esp + 0x18], 0
mov eax, ecx
mov dword [esp + 0x10], ebx
push esi
mov esi, dword [ebp + 8]
mov dword [esp + 0x30], eax
mov ecx, dword [eax + 0x34]
mov dword [esp + 0x74], esi
mov dword [esp + 0x70], ebx
mov dword [esp + 0x150], ebx
mov byte [esp + 0x154], bl
mov dword [esp + 0xbc], ebx
mov dword [esp + 0xc4], ebx
mov dword [esp + 0x34], ecx
push edi
test esi, esi
jne 0x1006bddb
lea eax, [esi + 7]
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x150]
xor ecx, esp
call fcn.1015c875
mov esp, ebp
pop ebp
ret
movzx esi, word [eax + 0x18]
movzx ecx, byte [eax + 0xc]
lea edi, [ecx + esi]
cmp edi, 2
jae 0x1006bdef
xor edx, edx
jmp 0x1006be0c
test edx, edx
je 0x1006be02
cmp edx, edi
jne 0x1006be01
mov eax, dword [ebp + 0x10]
lea edx, [eax - 2]
add edx, edi
jmp 0x1006be05
dec edx
mov eax, dword [ebp + 0x10]
mov edi, 2
sub edi, eax
lea eax, [edi + 1]
mov dword [esp + 0x54], edx
mov dword [esp + 0x44], eax
mov eax, edx
sub eax, ecx
mov dword [esp + 0x64], edi
lea ecx, [eax + edi]
cmp ecx, esi
jne 0x1006be38
mov eax, dword [esp + 0x34]
movzx ecx, byte [eax + 9]
mov eax, dword [eax + 0x38]
add ecx, 8
add ecx, eax
jmp 0x1006be53
mov edx, dword [esp + 0x34]
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 esi, [esp + 0x134]
push 0
bswap edx
mov dword [esp + 0x50], ecx
lea esi, [esi + edi*4]
mov ecx, dword [esp + 0x3c]
push 0
push esi
mov dword [esp + 0x5c], edx
mov dword [esp + 0x3c], edx
call fcn.10066070
add esp, 0xc
mov dword [esp + 0x14], eax
mov dword [esp + 0x24], eax
test eax, eax
jne 0x1006c02f
nop
mov ecx, dword [esi]
mov edx, edi
mov dword [esp + 0x1c], edx
cmp dword [ecx + 0x14], 0
jge 0x1006beb7
call fcn.10065b00
mov esi, eax
mov dword [esp + 0x14], esi
mov dword [esp + 0x24], esi
test esi, esi
jne 0x1006c0c6
mov edx, edi
mov eax, edi
dec edi
test eax, eax
je 0x1006c100
mov esi, dword [esp + 0x34]
mov al, byte [esi + 0xc]
test al, al
je 0x1006bf1e
mov eax, dword [esp + 0x54]
movzx ecx, word [esi + 0x1c]
add eax, edi
cmp eax, ecx
jne 0x1006bf1b
mov eax, dword [esi + 0x24]
push eax
push esi
mov esi, dword [esi + 0x4c]
mov ecx, dword [eax]
bswap ecx
mov dword [esp + 0x58], ecx
mov dword [esp + 0x38], ecx
mov ecx, esi
mov dword [esp + edi*4 + 0x70], eax
call dword [0x1019a4f8]
call esi
movzx eax, ax
lea esi, [edi*4]
mov dword [esp + esi + 0x88], eax
mov eax, dword [esp + 0x3c]
mov byte [eax + 0xc], 0
jmp 0x1006bffe
mov al, byte [esi + 0xc]
movzx eax, al
mov ecx, edx
sub ecx, eax
mov eax, dword [esi + 0x40]
add ecx, dword [esp + 0x54]
mov ax, word [eax + ecx*2 - 2]
mov ch, al
mov cl, ah
movzx eax, word [esi + 0x1a]
movzx ecx, cx
and ecx, eax
lea eax, [edx*4 - 4]
add ecx, dword [esi + 0x38]
mov dword [esp + eax + 0x68], ecx
mov dword [esp + 0x28], eax
push ecx
mov eax, dword [ecx]
bswap eax
push esi
mov esi, dword [esi + 0x4c]
mov dword [esp + 0x34], ecx
mov ecx, esi
mov dword [esp + 0x58], eax
mov dword [esp + 0x38], eax
call dword [0x1019a4f8]
call esi
mov ecx, dword [esp + 0x40]
add esp, 8
mov esi, dword [esp + 0x28]
movzx eax, ax
mov dword [esp + 0x40], eax
test byte [ecx + 0x18], 0xc
mov dword [esp + esi + 0x80], eax
je 0x1006bfda
mov ebx, dword [esp + 0x34]
mov edx, dword [esp + 0x2c]
mov ecx, edx
sub ecx, dword [ebx + 0x38]
mov ebx, dword [esp + 0x38]
add eax, ecx
cmp eax, dword [ebx + 0x28]
mov ebx, 0
jg 0x1006c0d2
push dword [esp + 0x40]
mov eax, dword [esp + 0x7c]
push edx
add eax, ecx
push eax
call fcn.1015f8f0
mov ecx, dword [esp + 0x40]
add esp, 0xc
mov eax, dword [esp + 0x78]
sub eax, dword [ecx + 0x38]
add eax, dword [esp + 0x2c]
mov dword [esp + esi + 0x68], eax
mov eax, dword [esp + 0x40]
mov edx, dword [esp + 0x54]
lea ecx, [esp + 0x24]
push ecx
mov ecx, dword [esp + 0x20]
dec edx
push eax
mov eax, dword [esp + 0x3c]
movzx eax, byte [eax + 0xc]
sub ecx, eax
add edx, ecx
mov ecx, dword [esp + 0x3c]
call fcn.1006acb0
mov edx, dword [esp + 0x58]
lea eax, [esp + 0x13c]
mov ecx, dword [esp + 0x40]
add esp, 8
add esi, eax
push 0
push 0
push esi
call fcn.10066070
add esp, 0xc
mov dword [esp + 0x14], eax
mov dword [esp + 0x24], eax
test eax, eax
je 0x1006be90
lea eax, [edi*4 + 4]
push eax
lea eax, [esp + 0x138]
push 0
push eax
call fcn.10160450
add esp, 0xc
xor ebx, ebx
cmp dword [esp + 0x44], ebx
jle 0x1006d213
nop word [eax + eax]
mov edx, dword [esp + ebx*4 + 0x134]
test edx, edx
je 0x1006d208
mov edx, dword [edx + 0x48]
test byte [edx + 0x1c], 0x20
je 0x1006d201
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.1015da40
push edx
push eax
push esi
mov esi, dword [edi + 0x48]
mov ecx, esi
call dword [0x1019a4f8]
call esi
add esp, 0x10
jmp 0x1006d208
lea eax, [edi*4]
jmp 0x1006c036
push 0x101d00b4
push 0x1192d
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call fcn.10054150
add esp, 0x14
mov dword [esp + 0x14], 0xb
lea eax, [esi + 4]
jmp 0x1006c036
mov eax, dword [esp + 0x38]
mov esi, dword [eax + 0x24]
mov eax, 0xaaaaaaab
lea ecx, [esi - 8]
mul ecx
mov edi, edx
shr edi, 2
add edi, 4
imul edi, dword [esp + 0x44]
add edi, 3
and edi, 0xfffffffc
lea eax, [edi + edi*2]
lea eax, [esi + eax*2]
cdq
push edx
push eax
call fcn.10051440
add esp, 8
mov dword [esp + 0xc8], eax
test eax, eax
jne 0x1006c14d
mov dword [esp + 0x14], 7
jmp 0x1006c049
mov ecx, dword [esp + 0x134]
lea eax, [eax + edi*4]
mov dword [esp + 0xcc], eax
lea eax, [eax + edi*2]
mov dword [esp + 0x28], eax
mov dword [esp + 0xc4], ecx
movzx eax, byte [ecx + 8]
shl ax, 2
movzx eax, ax
mov dword [esp + 0x5c], eax
mov al, byte [ecx + 3]
mov byte [esp + 0x13], al
movzx eax, al
mov dword [esp + 0xa8], eax
xor eax, eax
mov dword [esp + 0x1c], eax
cmp dword [esp + 0x44], eax
jle 0x1006c3df
nop dword [eax]
shl eax, 2
mov dword [esp + 0x48], eax
mov edi, dword [esp + eax + 0x134]
mov dword [esp + 0x58], edi
movzx eax, word [edi + 0x18]
mov edx, dword [edi + 0x38]
movzx esi, word [edi + 0x12]
mov dword [esp + 0x2c], eax
add esi, edx
movzx eax, word [edi + 0x1a]
mov ecx, eax
mov dword [esp + 0x60], eax
mov eax, dword [esp + 0x134]
mov dword [esp + 0x7c], ecx
mov dword [esp + 0x40], edx
mov dword [esp + 0x3c], esi
mov ecx, dword [eax + 0x38]
mov al, byte [edx]
cmp al, byte [ecx]
jne 0x1006c5f8
movzx eax, byte [edi + 0xc]
add eax, dword [esp + 0x2c]
mov ecx, dword [esp + 0xcc]
add eax, eax
push eax
mov eax, dword [esp + 0xc4]
push 0
lea eax, [ecx + eax*2]
push eax
call fcn.10160450
mov al, byte [edi + 0xc]
add esp, 0xc
test al, al
je 0x1006c2b6
movzx edx, word [edi + 0x1c]
cmp dword [esp + 0x2c], edx
jb 0x1006c5e9
test edx, edx
je 0x1006c27e
mov edi, dword [esp + 0x40]
mov ebx, dword [esp + 0xc0]
nop dword [eax]
mov ax, word [esi]
add esi, 2
mov ch, al
mov cl, ah
mov eax, dword [esp + 0x7c]
movzx ecx, cx
movzx eax, ax
and ecx, eax
mov eax, dword [esp + 0xc8]
add ecx, edi
mov dword [eax + ebx*4], ecx
inc ebx
sub edx, 1
jne 0x1006c240
mov edi, dword [esp + 0x58]
mov dword [esp + 0xc0], ebx
mov ebx, dword [esp + 0x18]
mov dword [esp + 0x3c], esi
mov al, byte [edi + 0xc]
xor edx, edx
test al, al
je 0x1006c2b6
mov ebx, dword [esp + 0xc0]
lea ecx, [edi + 0x24]
mov esi, dword [esp + 0xc8]
mov eax, dword [ecx]
lea ecx, [ecx + 4]
mov dword [esi + ebx*4], eax
inc edx
movzx eax, byte [edi + 0xc]
inc ebx
cmp edx, eax
jl 0x1006c295
mov esi, dword [esp + 0x3c]
mov dword [esp + 0xc0], ebx
mov ebx, dword [esp + 0x18]
movzx eax, word [edi + 0x12]
add eax, dword [esp + 0x40]
movzx ecx, word [edi + 0x18]
lea edx, [eax + ecx*2]
cmp esi, edx
jae 0x1006c30a
mov edi, dword [esp + 0x40]
mov ebx, dword [esp + 0xc0]
mov ax, word [esi]
add esi, 2
mov ch, al
mov cl, ah
mov eax, dword [esp + 0x60]
movzx ecx, cx
movzx eax, ax
and ecx, eax
mov eax, dword [esp + 0xc8]
add ecx, edi
mov dword [eax + ebx*4], ecx
inc ebx
cmp esi, edx
jb 0x1006c2d4
mov edi, dword [esp + 0x58]
mov dword [esp + 0xc0], ebx
mov ebx, dword [esp + 0x18]
mov ecx, dword [esp + 0x48]
mov eax, dword [esp + 0x1c]
mov edx, dword [esp + 0xc0]
mov dword [esp + ecx + 0xac], edx
cmp eax, dword [esp + 0x64]
jge 0x1006c3d0
cmp byte [esp + 0x13], 0
jne 0x1006c3d0
movzx eax, word [esp + ecx + 0x80]
mov ecx, dword [esp + 0xcc]
mov esi, dword [esp + 0x28]
push eax
add esi, ebx
add ebx, eax
mov word [ecx + edx*2], ax
mov eax, dword [esp + 0x4c]
mov dword [esp + 0x1c], ebx
push dword [esp + eax + 0x6c]
push esi
call fcn.1015f8f0
mov eax, dword [esp + 0x68]
add esp, 0xc
mov edx, dword [esp + 0xc0]
mov ecx, dword [esp + 0xcc]
movzx eax, ax
add eax, esi
mov esi, dword [esp + 0xc8]
mov dword [esi + edx*4], eax
mov eax, dword [esp + 0x5c]
sub word [ecx + edx*2], ax
cmp byte [edi + 8], 0
jne 0x1006c3a2
mov eax, dword [edi + 0x38]
mov ecx, dword [esi + edx*4]
mov eax, dword [eax + 8]
mov dword [ecx], eax
jmp 0x1006c3c4
cmp word [ecx + edx*2], 4
jae 0x1006c3c4
mov eax, dword [esp + 0x28]
nop dword [eax]
mov byte [eax + ebx], 0
inc ebx
inc word [ecx + edx*2]
cmp word [ecx + edx*2], 4
jb 0x1006c3b0
mov dword [esp + 0x18], ebx
mov eax, dword [esp + 0x1c]
inc edx
mov dword [esp + 0xc0], edx
inc eax
mov dword [esp + 0x1c], eax
cmp eax, dword [esp + 0x44]
jl 0x1006c1a0
mov eax, dword [esp + 0x5c]
xor ecx, ecx
movzx ebx, ax
xor esi, esi
mov eax, dword [esp + 0x38]
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x58], esi
mov eax, dword [eax + 0x28]
add eax, 0xfffffff4
add ebx, eax
mov eax, dword [esp + 0x44]
mov dword [esp + 0x40], ebx
test eax, eax
jle 0x1006c4fb
nop
mov edi, dword [esp + esi*4 + 0x134]
mov edx, dword [esp + esi*4 + 0xac]
mov dword [esp + 0x60], edx
mov eax, dword [edi + 0x3c]
mov dword [esp + ecx*4 + 0xd0], eax
mov dword [esp + ecx*4 + 0xe8], edx
test ecx, ecx
je 0x1006c445
cmp edx, dword [esp + ecx*4 + 0xe4]
jne 0x1006c445
dec ecx
mov dword [esp + 0x1c], ecx
cmp byte [esp + 0x13], 0
jne 0x1006c469
mov eax, dword [esp + 0x34]
inc ecx
mov dword [esp + 0x1c], ecx
mov eax, dword [eax + 0x3c]
mov dword [esp + ecx*4 + 0xd0], eax
lea eax, [edx + 1]
mov dword [esp + ecx*4 + 0xe8], eax
sub ebx, dword [edi + 0x14]
lea eax, [esp + 0x80]
cmp byte [edi + 0xc], 0
lea eax, [eax + esi*4]
mov dword [esp + 0x64], eax
mov dword [eax], ebx
mov dword [esp + 0x28], 0
jbe 0x1006c4da
lea ecx, [edi + 0x24]
mov dword [esp + 0x48], ecx
push dword [ecx]
mov esi, dword [edi + 0x4c]
mov ecx, esi
push edi
call dword [0x1019a4f8]
call esi
mov edx, dword [esp + 0x30]
add esp, 8
mov ecx, dword [esp + 0x48]
inc edx
movzx eax, ax
add ecx, 4
add eax, 2
mov dword [esp + 0x28], edx
add ebx, eax
mov dword [esp + 0x48], ecx
movzx eax, byte [edi + 0xc]
cmp edx, eax
jl 0x1006c491
mov eax, dword [esp + 0x64]
mov ecx, dword [esp + 0x1c]
mov edx, dword [esp + 0x60]
mov esi, dword [esp + 0x58]
mov dword [eax], ebx
mov eax, dword [esp + 0x44]
inc ecx
mov ebx, dword [esp + 0x40]
mov dword [esp + esi*4 + 0x94], edx
inc esi
mov dword [esp + 0x58], esi
mov dword [esp + 0x1c], ecx
cmp esi, eax
jl 0x1006c410
mov ebx, dword [esp + 0xc0]
mov edx, eax
mov dword [esp + 0x18], edx
mov dword [esp + 0x2c], 0
test eax, eax
jle 0x1006c718
mov eax, 1
xor ecx, ecx
mov dword [esp + 0x1c], eax
mov dword [esp + 0x3c], ecx
nop word [eax + eax]
mov edi, dword [esp + ecx + 0x80]
cmp edi, dword [esp + 0x40]
jle 0x1006c64c
cmp eax, edx
jl 0x1006c56e
lea edx, [eax + 1]
mov dword [esp + 0x18], edx
cmp edx, 5
jg 0x1006c7d2
mov dword [esp + ecx + 0x84], 0
mov edi, dword [esp + ecx + 0x80]
mov dword [esp + ecx + 0x98], ebx
mov esi, dword [esp + ecx + 0x94]
mov edx, dword [esp + 0xcc]
lea ebx, [esi - 1]
movzx eax, word [edx + ebx*2]
test ax, ax
jne 0x1006c5a4
mov edx, ebx
lea ecx, [esp + 0xc0]
call fcn.1006b020
mov ecx, dword [esp + 0x3c]
mov edx, dword [esp + 0xcc]
movzx eax, ax
movzx eax, ax
add eax, 2
sub edi, eax
cmp byte [esp + 0x13], 0
mov dword [esp + ecx + 0x80], edi
jne 0x1006c625
cmp esi, dword [esp + 0xc0]
jge 0x1006c623
movzx eax, word [edx + esi*2]
test ax, ax
jne 0x1006c5dd
mov edx, esi
lea ecx, [esp + 0xc0]
call fcn.1006b020
movzx eax, ax
mov ecx, dword [esp + 0x3c]
movzx eax, ax
add eax, 2
jmp 0x1006c625
mov ecx, 0x11988
call fcn.100dfa60
jmp 0x1006d1e0
push 0x101d00b4
push 0x11970
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call fcn.10054150
add esp, 0x14
mov dword [esp + 0x14], 0xb
jmp 0x1006d1e4
xor eax, eax
add dword [esp + ecx + 0x84], eax
mov eax, dword [esp + 0x1c]
mov edx, dword [esp + 0x18]
mov dword [esp + ecx + 0x94], ebx
mov ebx, dword [esp + 0xc0]
cmp edi, dword [esp + 0x40]
jg 0x1006c541
mov esi, dword [esp + ecx + 0x94]
cmp esi, ebx
jge 0x1006c6f5
mov edx, dword [esp + 0xcc]
movzx eax, word [edx + esi*2]
test ax, ax
jne 0x1006c687
mov edx, esi
lea ecx, [esp + 0xc0]
call fcn.1006b020
mov ecx, dword [esp + 0x3c]
mov edx, dword [esp + 0xcc]
movzx eax, ax
movzx eax, ax
add eax, 2
add edi, eax
cmp edi, dword [esp + 0x40]
jg 0x1006c7a7
inc esi
mov dword [esp + ecx + 0x80], edi
cmp byte [esp + 0x13], 0
mov dword [esp + ecx + 0x94], esi
jne 0x1006c6e2
cmp esi, ebx
jge 0x1006c6e0
movzx eax, word [edx + esi*2]
test ax, ax
jne 0x1006c6d4
mov edx, esi
lea ecx, [esp + 0xc0]
call fcn.1006b020
mov edx, dword [esp + 0xcc]
movzx eax, ax
mov ecx, dword [esp + 0x3c]
movzx eax, ax
add eax, 2
jmp 0x1006c6e2
xor eax, eax
sub dword [esp + ecx + 0x84], eax
cmp esi, ebx
jl 0x1006c662
mov eax, dword [esp + 0x1c]
mov edx, eax
mov dword [esp + 0x18], edx
mov esi, dword [esp + 0x2c]
add ecx, 4
inc esi
mov dword [esp + 0x3c], ecx
inc eax
mov dword [esp + 0x2c], esi
mov dword [esp + 0x1c], eax
cmp esi, edx
jl 0x1006c530
lea eax, [edx - 1]
mov ecx, eax
mov dword [esp + 0x3c], eax
test ecx, ecx
jle 0x1006c92e
nop dword [eax]
shl ecx, 2
lea eax, [esp + 0x80]
add eax, ecx
mov dword [esp + 0x64], ecx
mov dword [esp + 0x58], eax
mov edi, dword [eax]
lea eax, [esp + ecx + 0x7c]
mov dword [esp + 0x68], eax
mov eax, dword [eax]
mov dword [esp + 0x1c], eax
lea eax, [esp + 0x94]
sub eax, 4
mov dword [esp + 0x48], eax
mov eax, dword [eax + ecx]
mov ecx, dword [esp + 0xcc]
mov dword [esp + 0x28], eax
lea esi, [eax - 1]
mov edx, esi
sub edx, dword [esp + 0xa8]
inc edx
cmp word [ecx + edx*2], 0
lea eax, [ecx + edx*2]
mov dword [esp + 0x2c], eax
jne 0x1006c79e
lea ecx, [esp + 0xc0]
call fcn.1006b020
mov ecx, dword [esp + 0xcc]
mov ebx, dword [esp + 0x2c]
jmp 0x1006c837
cmp esi, ebx
jge 0x1006c6f1
cmp dword [esp + 0x2c], 0
jle 0x1006c7bf
mov eax, dword [esp + ecx + 0x90]
jmp 0x1006c7c1
xor eax, eax
cmp esi, eax
jle 0x1006c7fd
mov eax, dword [esp + 0x1c]
mov edx, dword [esp + 0x18]
jmp 0x1006c6fb
push 0x101d00b4
push 0x119ed
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call fcn.10054150
add esp, 0x14
mov dword [esp + 0x14], 0xb
jmp 0x1006d1e4
push 0x101d00b4
push 0x11a0e
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call fcn.10054150
add esp, 0x14
mov dword [esp + 0x14], 0xb
jmp 0x1006d1e4
mov ecx, dword [esp + 0xcc]
cmp word [ecx + esi*2], 0
mov dword [esp + 0x7c], esi
mov dword [esp + 0x60], esi
jne 0x1006c854
mov edx, esi
lea ecx, [esp + 0xc0]
call fcn.1006b020
test edi, edi
je 0x1006c8a1
cmp dword [ebp + 0x10], 0
mov eax, dword [esp + 0x28]
mov edx, eax
jne 0x1006c8e6
mov ecx, dword [esp + 0x18]
mov eax, 2
mov ebx, dword [esp + 0x2c]
dec ecx
cmp dword [esp + 0x3c], ecx
mov ecx, 0
cmove eax, ecx
mov ecx, dword [esp + 0x1c]
sub ecx, eax
mov eax, dword [esp + 0xcc]
movzx eax, word [eax + esi*2]
sub ecx, eax
movzx eax, word [ebx]
add eax, 2
add eax, edi
cmp eax, ecx
jg 0x1006c8e6
movzx eax, word [ebx]
mov ecx, 0xfffffffe
mov edx, dword [esp + 0x7c]
add eax, 2
add edi, eax
sub ebx, 2
mov eax, dword [esp + 0xcc]
mov dword [esp + 0x2c], ebx
movzx eax, word [eax + esi*2]
sub ecx, eax
mov eax, dword [esp + 0x64]
add dword [esp + 0x1c], ecx
mov ecx, dword [esp + 0x48]
mov dword [ecx + eax], esi
sub esi, 1
mov eax, dword [esp + 0x60]
mov dword [esp + 0x28], eax
jns 0x1006c830
mov eax, dword [esp + 0x58]
mov ecx, dword [esp + 0x68]
mov ebx, dword [esp + 0xc0]
mov dword [eax], edi
mov eax, dword [esp + 0x1c]
mov dword [ecx], eax
mov ecx, dword [esp + 0x3c]
cmp ecx, 1
jle 0x1006c917
mov esi, dword [esp + 0x48]
lea eax, [ecx*4]
mov eax, dword [eax + esi - 4]
jmp 0x1006c919
xor eax, eax
cmp edx, eax
jle 0x1006c998
dec ecx
mov dword [esp + 0x3c], ecx
test ecx, ecx
jg 0x1006c730
mov edx, dword [esp + 0x18]
mov eax, dword [esp + 0x134]
xor esi, esi
mov eax, dword [eax + 0x38]
movzx eax, byte [eax]
mov dword [esp + 0x48], eax
lea eax, [esi + 1]
test edx, edx
jle 0x1006caaf
nop dword [eax]
cmp esi, dword [esp + 0x44]
jge 0x1006ca0a
mov eax, dword [esp + esi*4 + 0x134]
mov dword [esp + esi*4 + 0x140], eax
mov dword [esp + esi*4 + 0x134], 0
mov dword [esp + 0x28], eax
mov ecx, dword [eax + 0x48]
test byte [ecx + 0x1c], 4
mov edx, dword [ecx + 0x14]
je 0x1006c9c7
mov eax, dword [edx + 0x18]
cmp eax, dword [ecx + 0x18]
jb 0x1006c9c7
cmp dword [edx + 0x60], 0
je 0x1006c9c3
call fcn.1005ebf0
jmp 0x1006c9ec
push 0x101d00b4
push 0x11a38
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call fcn.10054150
add esp, 0x14
mov dword [esp + 0x14], 0xb
jmp 0x1006d1e4
xor eax, eax
jmp 0x1006c9ec
mov eax, dword [edx + 0x28]
mov dword [esp + 0x14], eax
test eax, eax
jne 0x1006c9f0
mov eax, dword [edx + 0x94]
cmp eax, dword [edx + 0x98]
jbe 0x1006c9e7
call fcn.100604f0
jmp 0x1006c9ec
call fcn.100602c0
mov dword [esp + 0x14], eax
mov edi, dword [esp + 0x20]
inc edi
mov dword [esp + 0x24], eax
mov dword [esp + 0x20], edi
test eax, eax
jne 0x1006d1e4
jmp 0x1006ca9d
cmp dword [ebp + 0x10], 0
lea edx, [esp + 0x28]
mov ecx, dword [esp + 0x50]
cmovne ecx, eax
lea eax, [esp + 0x30]
push 0
push ecx
mov ecx, dword [esp + 0x40]
push eax
call fcn.10069d70
add esp, 0xc
mov dword [esp + 0x14], eax
mov dword [esp + 0x24], eax
test eax, eax
jne 0x1006d1e4
mov edi, dword [esp + 0x28]
mov ecx, edi
mov edx, dword [esp + 0x48]
call fcn.10065e70
mov ecx, dword [esp + 0x38]
inc dword [esp + 0x20]
mov dword [esp + esi*4 + 0x140], edi
mov dword [esp + esi*4 + 0xac], ebx
cmp byte [ecx + 0x11], 0
je 0x1006ca91
mov edx, dword [edi + 4]
lea eax, [esp + 0x24]
push eax
mov eax, dword [esp + 0x38]
push dword [eax + 4]
push 5
call fcn.10064bd0
mov edi, dword [esp + 0x30]
add esp, 0xc
mov dword [esp + 0x14], edi
test edi, edi
jne 0x1006d1e4
mov edx, dword [esp + 0x30]
mov edi, dword [esp + 0x20]
mov dword [esp + 0x50], edx
inc esi
mov eax, 1
cmp esi, dword [esp + 0x18]
jl 0x1006c950
jmp 0x1006cab1
xor edi, edi
xor ecx, ecx
test edi, edi
jle 0x1006cb07
nop word [eax + eax]
mov eax, dword [esp + ecx*4 + 0x140]
mov edx, dword [eax + 4]
mov eax, dword [eax + 0x48]
mov dword [esp + ecx*4 + 0x118], edx
mov dword [esp + ecx*4 + 0x100], edx
mov ax, word [eax + 0x1c]
mov word [esp + ecx*2 + 0x68], ax
xor eax, eax
test ecx, ecx
jle 0x1006cb02
nop word [eax + eax]
cmp dword [esp + eax*4 + 0x118], edx
je 0x1006cc90
inc eax
cmp eax, ecx
jl 0x1006caf0
inc ecx
cmp ecx, edi
jl 0x1006cac0
xor ebx, ebx
mov dword [esp + 0x28], ebx
test edi, edi
jle 0x1006cbc0
xor esi, esi
lea ecx, [esi + 1]
cmp edi, ecx
jle 0x1006cb54
mov ebx, dword [esp + 0x20]
xor edi, edi
nop dword [eax]
nop dword [eax + eax]
lea edx, [ecx*4]
mov eax, dword [esp + edx + 0x100]
cmp eax, dword [esp + edi + 0x100]
jae 0x1006cb4b
mov esi, ecx
mov edi, edx
inc ecx
cmp ecx, ebx
jl 0x1006cb30
mov ebx, dword [esp + 0x28]
mov edi, dword [esp + esi*4 + 0x100]
mov dword [esp + esi*4 + 0x100], 0xffffffff
cmp esi, ebx
je 0x1006cbaf
jle 0x1006cb8b
mov eax, dword [esp + 0x38]
mov edx, dword [eax + 0x30]
mov eax, dword [esp + esi*4 + 0x140]
inc edx
add edx, esi
mov ecx, dword [eax + 0x48]
xor eax, eax
mov word [ecx + 0x1c], ax
call fcn.1005a790
mov eax, dword [esp + ebx*4 + 0x140]
mov edx, edi
mov ecx, dword [eax + 0x48]
mov ax, word [esp + esi*2 + 0x68]
mov word [ecx + 0x1c], ax
call fcn.1005a790
mov eax, dword [esp + ebx*4 + 0x140]
mov dword [eax + 4], edi
mov edi, dword [esp + 0x20]
inc ebx
mov dword [esp + 0x28], ebx
cmp ebx, edi
jl 0x1006cb15
test byte [esp + 0x48], 8
mov eax, dword [esp + edi*4 + 0x13c]
mov ecx, dword [esp + 0x4c]
mov eax, dword [eax + 4]
bswap eax
mov dword [ecx], eax
jne 0x1006cc09
mov ecx, dword [esp + 0x44]
cmp ecx, edi
je 0x1006cc09
lea edx, [esp + 0x134]
lea eax, [esp + 0x140]
cmovge eax, edx
mov eax, dword [eax + ecx*4 - 4]
mov edx, dword [eax + 0x38]
mov eax, dword [esp + edi*4 + 0x13c]
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 0x1006ce44
mov edi, dword [esp + 0x140]
xor ebx, ebx
xor esi, esi
mov dword [esp + 0x4c], 0
mov dword [esp + 0x50], esi
movzx edx, word [edi + 0x18]
movzx eax, byte [edi + 0xc]
add edx, eax
mov dword [esp + 0x30], edx
cmp dword [esp + 0xc0], ebx
jle 0x1006ce4b
mov eax, edi
mov dword [esp + 0x28], ebx
mov dword [esp + 0x18], eax
nop dword [eax]
nop word [eax + eax]
mov ecx, dword [esp + 0xc8]
mov ecx, dword [ecx + esi*4]
mov dword [esp + 0x2c], ecx
cmp esi, edx
jne 0x1006cce2
xor eax, eax
cmp byte [esp + 0x13], al
sete al
mov dword [esp + 0x68], eax
nop
inc ebx
cmp ebx, dword [esp + 0x20]
jge 0x1006ccbb
mov edi, dword [esp + ebx*4 + 0x140]
jmp 0x1006ccc2
push 0x101d00b4
push 0x11a82
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call fcn.10054150
add esp, 0x14
mov dword [esp + 0x14], 0xb
jmp 0x1006d1e4
mov edi, dword [esp + ebx*4 + 0x134]
movzx eax, word [edi + 0x18]
add eax, dword [esp + 0x68]
movzx ecx, byte [edi + 0xc]
add ecx, eax
add edx, ecx
cmp esi, edx
je 0x1006cc80
mov ecx, dword [esp + 0x2c]
mov eax, dword [esp + 0x18]
mov dword [esp + 0x30], edx
mov edx, dword [esp + 0x28]
cmp esi, dword [esp + edx + 0x94]
mov edx, dword [esp + 0x30]
jne 0x1006cd19
mov eax, dword [esp + 0x4c]
inc eax
mov dword [esp + 0x4c], eax
shl eax, 2
cmp byte [esp + 0x13], 0
mov dword [esp + 0x28], eax
mov eax, dword [esp + eax + 0x140]
mov dword [esp + 0x18], eax
je 0x1006ce32
cmp ebx, dword [esp + 0x20]
jge 0x1006cd3d
mov eax, dword [eax + 4]
cmp eax, dword [esp + ebx*4 + 0x118]
mov eax, dword [esp + 0x18]
jne 0x1006cd3d
cmp ecx, dword [edi + 0x38]
jb 0x1006cd3d
cmp ecx, dword [edi + 0x3c]
jb 0x1006ce32
cmp word [esp + 0x5c], 0
jne 0x1006cd67
lea edx, [esp + 0x24]
push edx
push dword [eax + 4]
mov edx, dword [ecx]
mov ecx, dword [esp + 0x40]
push 5
bswap edx
call fcn.10064bd0
mov eax, dword [esp + 0x30]
add esp, 0xc
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0xcc]
movzx eax, word [eax + esi*2]
test ax, ax
jne 0x1006cd88
mov edx, esi
lea ecx, [esp + 0xc0]
call fcn.1006b020
movzx eax, ax
mov ecx, dword [esp + 0x18]
cmp ax, word [ecx + 0x10]
jbe 0x1006ce19
cmp dword [esp + 0x14], 0
jne 0x1006d1e4
mov esi, dword [ecx + 0x50]
lea eax, [esp + 0x100]
push eax
push dword [esp + 0x30]
push ecx
mov ecx, esi
call dword [0x1019a4f8]
call esi
movzx eax, word [esp + 0x11c]
add esp, 0xc
cmp eax, dword [esp + 0x10c]
jae 0x1006ce26
mov ecx, dword [edi + 0x3c]
mov edx, dword [esp + 0x2c]
cmp ecx, edx
jb 0x1006cde4
add eax, edx
cmp ecx, eax
jb 0x1006ceba
mov ecx, dword [esp + 0x18]
lea eax, [esp + 0x24]
push eax
movzx eax, word [esp + 0x116]
push dword [ecx + 4]
mov ecx, dword [ecx + 0x34]
mov edx, dword [eax + edx - 4]
push 3
bswap edx
call fcn.10064bd0
mov eax, dword [esp + 0x30]
add esp, 0xc
mov esi, dword [esp + 0x50]
mov dword [esp + 0x14], eax
jmp 0x1006ce1d
mov eax, dword [esp + 0x14]
test eax, eax
je 0x1006ce2a
jmp 0x1006d1e4
mov esi, dword [esp + 0x50]
mov eax, dword [esp + 0x18]
mov edx, dword [esp + 0x30]
inc esi
mov dword [esp + 0x50], esi
cmp esi, dword [esp + 0xc0]
jl 0x1006cc60
mov edi, dword [esp + 0x140]
mov eax, dword [esp + 0x20]
xor ebx, ebx
dec eax
test eax, eax
jle 0x1006cff0
nop word [eax + eax]
mov eax, dword [esp + ebx*4 + 0x94]
mov edx, dword [esp + 0xc8]
mov edi, dword [edx + eax*4]
lea edx, [edx + eax*4]
mov ecx, dword [esp + ebx*4 + 0x140]
mov esi, dword [esp + 0x74]
add esi, dword [esp + 0x78]
mov dword [esp + 0x68], edx
mov edx, dword [esp + 0xcc]
mov dword [esp + 0x30], ecx
mov ecx, dword [esp + 0x5c]
mov dword [esp + 0x4c], esi
movzx eax, word [edx + eax*2]
movzx edx, cx
mov ecx, dword [esp + 0x30]
add edx, eax
cmp byte [ecx + 8], 0
jne 0x1006cee5
mov ecx, dword [ecx + 0x38]
mov eax, dword [edi]
mov dword [ecx + 8], eax
jmp 0x1006cfa5
push 0x101d00b4
push 0x100bc
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call fcn.10054150
add esp, 0x14
mov dword [esp + 0x14], 0xb
jmp 0x1006d1e4
cmp byte [esp + 0x13], 0
je 0x1006cf80
mov esi, dword [ecx + 0x50]
lea eax, [esp + 0x118]
push eax
mov eax, dword [esp + 0x6c]
push dword [eax - 4]
push ecx
mov ecx, esi
call dword [0x1019a4f8]
call esi
mov eax, dword [esp + 0x58]
add esp, 0xc
mov edx, dword [esp + 0x11c]
mov edi, eax
mov ecx, dword [esp + 0x118]
lea esi, [eax + 4]
test edx, edx
ja 0x1006cf6d
jb 0x1006cf32
cmp ecx, 0x7f
ja 0x1006cf43
mov eax, 1
and cl, 0x7f
mov byte [esi], cl
xor esi, esi
lea edx, [eax + 4]
jmp 0x1006cfa5
test edx, edx
ja 0x1006cf6d
jb 0x1006cf51
cmp ecx, 0x3fff
ja 0x1006cf6d
mov eax, ecx
and cl, 0x7f
shrd eax, edx, 7
mov byte [esi + 1], cl
or al, 0x80
mov byte [esi], al
mov eax, 2
xor esi, esi
lea edx, [eax + 4]
jmp 0x1006cfa5
push edx
push ecx
mov ecx, esi
call fcn.10055930
add esp, 8
xor esi, esi
lea edx, [eax + 4]
jmp 0x1006cfa5
sub edi, 4
cmp eax, 4
jne 0x1006cfa9
mov eax, dword [esp + 0x34]
push edi
push eax
mov esi, dword [eax + 0x4c]
mov ecx, esi
call dword [0x1019a4f8]
call esi
mov esi, dword [esp + 0x54]
add esp, 8
movzx edx, ax
mov ecx, dword [esp + 0x30]
add dword [esp + 0x74], edx
lea eax, [esp + 0x24]
push eax
push dword [ecx + 4]
mov ecx, dword [esp + 0x3c]
push esi
push edx
mov edx, dword [esp + 0x64]
push edi
lea edx, [edx + ebx]
call fcn.1006add0
mov edi, dword [esp + 0x38]
add esp, 0x14
mov dword [esp + 0x14], edi
test edi, edi
jne 0x1006d1e4
mov eax, dword [esp + 0x20]
inc ebx
dec eax
cmp ebx, eax
jl 0x1006ce60
mov edi, dword [esp + 0x140]
mov esi, 1
sub esi, dword [esp + 0x20]
mov dword [esp + 0x4c], esi
cmp esi, dword [esp + 0x20]
jge 0x1006d0ee
nop word [eax + eax]
mov eax, esi
lea ebx, [esp + 0x154]
cdq
mov ecx, eax
xor ecx, edx
sub ecx, edx
add ebx, ecx
cmp byte [ebx], 0
jne 0x1006d0d8
test esi, esi
jns 0x1006d043
mov eax, dword [esp + ecx*4 + 0xa8]
cmp eax, dword [esp + ecx*4 + 0x90]
jl 0x1006d0d8
test ecx, ecx
jne 0x1006d054
mov esi, dword [esp + 0x94]
xor edx, edx
xor eax, eax
jmp 0x1006d08c
cmp ecx, dword [esp + 0x44]
jge 0x1006d06c
xor edx, edx
cmp byte [esp + 0x13], dl
sete dl
add edx, dword [esp + ecx*4 + 0xa8]
jmp 0x1006d073
mov edx, dword [esp + 0xc0]
mov esi, dword [esp + ecx*4 + 0x94]
xor eax, eax
cmp byte [esp + 0x13], al
sete al
add eax, dword [esp + ecx*4 + 0x90]
sub esi, eax
lea edi, [ecx*4]
lea ecx, [esp + 0xc0]
push ecx
mov ecx, dword [esp + edi + 0x144]
push esi
push eax
call fcn.1006b7a0
add esp, 0xc
mov dword [esp + 0x14], eax
mov dword [esp + 0x24], eax
test eax, eax
jne 0x1006d1e4
mov eax, dword [esp + edi + 0x140]
mov ecx, dword [esp + 0x40]
sub ecx, dword [esp + edi + 0x80]
mov esi, dword [esp + 0x4c]
mov byte [ebx], 1
mov dword [eax + 0x14], ecx
inc esi
mov dword [esp + 0x4c], esi
cmp esi, dword [esp + 0x20]
jl 0x1006d010
mov edi, dword [esp + 0x140]
cmp dword [ebp + 0xc], 0
je 0x1006d155
mov ebx, dword [esp + 0x34]
cmp word [ebx + 0x18], 0
jne 0x1006d155
movzx eax, byte [ebx + 9]
cmp eax, dword [edi + 0x14]
jg 0x1006d155
or edx, 0xffffffff
mov ecx, edi
call fcn.100651e0
mov ecx, dword [esp + 0x140]
mov edx, ebx
mov dword [esp + 0x24], eax
lea eax, [esp + 0x24]
push eax
call fcn.1006bc90
mov eax, dword [esp + 0x28]
add esp, 4
mov dword [esp + 0x14], eax
test eax, eax
jne 0x1006d1af
mov ecx, dword [esp + 0x140]
mov edx, ecx
push dword [ecx + 4]
mov ecx, dword [ecx + 0x34]
call fcn.1006a560
add esp, 4
mov dword [esp + 0x14], eax
jmp 0x1006d1af
mov ecx, dword [esp + 0x38]
cmp byte [ecx + 0x11], 0
je 0x1006d1ab
cmp word [esp + 0x5c], 0
mov edi, dword [esp + 0x20]
jne 0x1006d1a5
xor esi, esi
test edi, edi
jle 0x1006d1a5
mov eax, dword [esp + esi*4 + 0x140]
lea edx, [esp + 0x24]
push edx
push dword [eax + 4]
mov eax, dword [eax + 0x38]
push 5
mov edx, dword [eax + 8]
bswap edx
call fcn.10064bd0
mov ecx, dword [esp + 0x44]
inc esi
add esp, 0xc
cmp esi, edi
jl 0x1006d171
mov eax, dword [esp + 0x24]
mov dword [esp + 0x14], eax
jmp 0x1006d1b3
mov eax, dword [esp + 0x14]
jmp 0x1006d1b3
mov eax, dword [esp + 0x14]
mov edi, dword [esp + 0x20]
mov ebx, dword [esp + 0x44]
mov esi, edi
cmp edi, ebx
jge 0x1006d1e4
nop dword [eax]
mov ecx, dword [esp + esi*4 + 0x134]
test eax, eax
jne 0x1006d1db
push dword [ecx + 4]
mov edx, ecx
mov ecx, dword [ecx + 0x34]
call fcn.1006a560
add esp, 4
inc esi
cmp esi, ebx
jl 0x1006d1c0
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0xc8]
test eax, eax
je 0x1006c049
push eax
call fcn.100516f0
add esp, 4
jmp 0x1006c049
mov ecx, edx
call fcn.1005a500
inc ebx
cmp ebx, dword [esp + 0x44]
jl 0x1006c060
xor ebx, ebx
cmp dword [esp + 0x20], ebx
jle 0x1006d289
nop dword [eax + eax]
mov edx, dword [esp + ebx*4 + 0x140]
test edx, edx
je 0x1006d282
mov edx, dword [edx + 0x48]
test byte [edx + 0x1c], 0x20
je 0x1006d27b
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.1015da40
push edx
push eax
push esi
mov esi, dword [edi + 0x48]
mov ecx, esi
call dword [0x1019a4f8]
call esi
add esp, 0x10
jmp 0x1006d282
mov ecx, edx
call fcn.1005a500
inc ebx
cmp ebx, dword [esp + 0x20]
jl 0x1006d220
mov ecx, dword [esp + 0x15c]
mov eax, dword [esp + 0x14]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.1015c875
mov esp, ebp
pop ebp
ret