Function at 0x101300d0
Capabilities:
Reference sql statements
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x1c
push ebx
mov eax, ecx
xor ebx, ebx
xorps xmm0, xmm0
mov dword [esp + 8], eax
push esi
push edi
lea edi, [eax + 0x3c]
movlpd qword [esp + 0x20], xmm0
cmp dword [edi], ebx
jne 0x101301bd
mov ebx, dword [eax]
mov ecx, 0x10166843
mov eax, str._origin
push dword [ebx + 8]
cmp dword [ebx + 0x24], 0
push dword [ebx + 4]
cmove eax, ecx
push eax
push str.SELECT_sz_s_FROM__Q._q_docsize_WHERE_id_
call fcn.100294e0
mov esi, eax
add esp, 0x10
test esi, esi
jne 0x10130139
push dword [edi]
call fcn.10053c90
add esp, 4
lea eax, [esi + 7]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [esp + 0x10]
mov edx, esi
push 0
push edi
push 0
mov eax, dword [eax]
push 0x85
push 0xffffffffffffffff
inc dword [eax + 0x44]
mov ecx, dword [ebx]
call fcn.1009d7f0
mov ebx, eax
add esp, 0x14
mov eax, dword [esp + 0x10]
mov eax, dword [eax]
dec dword [eax + 0x44]
cmp dword [0x10177b48], 0
je 0x101301b3
mov eax, dword [0x1017ad00]
test eax, eax
je 0x10130181
push eax
call dword [0x10177b98]
add esp, 4
push esi
call dword [0x10177b74]
sub dword [0x1017ab88], eax
add esp, 4
dec dword [0x1017abac]
push esi
call dword [0x10177b6c]
mov eax, dword [0x1017ad00]
add esp, 4
test eax, eax
je 0x101301bd
push eax
call dword [0x10177ba0]
jmp 0x101301ba
push esi
call dword [0x10177b6c]
add esp, 4
mov esi, dword [edi]
mov edi, esi
push esi
call fcn.10053c90
add esp, 4
test ebx, ebx
jne 0x101303dd
push dword [ebp + 0xc]
push dword [ebp + 8]
push 1
push esi
call fcn.10056380
push esi
call fcn.10054c20
add esp, 0x14
cmp eax, 0x64
jne 0x10130295
test esi, esi
jne 0x10130209
mov ecx, 0x10161a88
call fcn.1004d340
mov ebx, eax
mov edi, edx
jmp 0x1013029d
mov eax, dword [esi]
mov eax, dword [eax + 0xc]
test eax, eax
je 0x1013021c
push eax
call dword [0x10177b98]
add esp, 4
mov eax, dword [esi + 0x78]
test eax, eax
je 0x10130236
mov ecx, 1
cmp cx, word [esi + 0x90]
jae 0x10130236
lea ecx, [eax + 0x28]
jmp 0x1013024e
mov ecx, dword [esi]
mov edx, 0x19
mov dword [ecx + 0x40], 0x19
call fcn.1002a360
mov ecx, 0x10161a88
call fcn.1004d340
mov ecx, dword [edi]
mov ebx, eax
mov dword [esp + 0xc], edx
mov edx, dword [edi + 0x24]
cmp byte [ecx + 0x57], 0
jne 0x1013026c
test edx, edx
jne 0x1013026c
xor eax, eax
jmp 0x10130271
call fcn.100272e0
mov dword [edi + 0x24], eax
mov eax, dword [edi]
mov eax, dword [eax + 0xc]
test eax, eax
je 0x1013028f
push eax
call dword [0x10177ba0]
mov ecx, dword [esp + 0x10]
add esp, 4
mov dword [esp + 0xc], ecx
mov edi, dword [esp + 0xc]
jmp 0x101302a1
mov edi, dword [esp + 0x24]
mov ebx, dword [esp + 0x20]
mov dword [esp + 0xc], edi
push esi
call fcn.10053c90
add esp, 4
test eax, eax
jne 0x101303df
mov ecx, ebx
or ecx, edi
je 0x101303df
mov eax, dword [esp + 0x10]
mov esi, dword [eax + 4]
mov dword [esp + 0x20], esi
cmp dword [esi + 0x60], 0
jne 0x101302ee
mov ecx, esi
call fcn.1011b6c0
cmp dword [esi + 0x2c], 0
mov dword [esi + 0x58], eax
mov dword [esi + 0x5c], edx
jne 0x101303cc
mov ecx, esi
call fcn.1011b4e0
mov dword [esi + 0x60], eax
cmp dword [esi + 0x2c], 0
jne 0x101303cc
mov eax, dword [esi + 0x60]
inc dword [eax]
mov edx, dword [esi + 0x60]
mov dword [esp + 0x14], edx
test edx, edx
je 0x101303cc
mov edi, dword [edx + 0x1c]
xor ecx, ecx
sub edi, 1
mov dword [esp + 0x18], ecx
mov dword [esp + 0x1c], edi
js 0x101303c5
lea eax, [edi + edi*2]
lea edx, [edx + eax*4]
mov eax, dword [esp + 0x14]
add edx, 0x28
mov dword [esp + 0x14], eax
mov dword [esp + 0x10], edx
mov esi, dword [edx - 4]
sub esi, 1
js 0x101303a9
mov eax, dword [esp + 0xc]
lea edi, [esi*8]
sub edi, esi
shl edi, 3
nop
mov edx, dword [edx]
add edx, edi
cmp dword [edx + 0x14], eax
ja 0x10130399
jb 0x10130360
cmp dword [edx + 0x10], ebx
ja 0x10130399
cmp dword [edx + 0x1c], eax
jb 0x10130399
ja 0x1013036c
cmp dword [edx + 0x18], ebx
jb 0x10130399
test ecx, ecx
jne 0x1013037f
add dword [edx + 0x28], 1
mov dword [esp + 0x18], 1
adc dword [edx + 0x2c], ecx
push dword [ebp + 0xc]
mov ecx, dword [esp + 0x24]
push dword [ebp + 8]
call fcn.10127c60
mov eax, dword [esp + 0x14]
add esp, 8
mov ecx, dword [esp + 0x18]
mov edx, dword [esp + 0x10]
sub edi, 0x38
sub esi, 1
jns 0x10130350
mov edi, dword [esp + 0x1c]
dec edi
sub edx, 0xc
mov dword [esp + 0x1c], edi
mov dword [esp + 0x10], edx
test edi, edi
jns 0x10130337
mov esi, dword [esp + 0x20]
mov edx, dword [esp + 0x14]
mov ecx, edx
call fcn.1011aca0
mov eax, dword [esi + 0x2c]
mov dword [esi + 0x2c], 0
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, ebx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret