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

Disassembly:
sub esp, 0xc0
push ebx
push ebp
push esi
mov esi, dword [esp + 0xd0]
mov ebx, dword [esp + 0xd4]
push edi
mov eax, dword [esi + 0x1e4]
mov ebp, dword [esi]
mov dword [esp + 0xa8], eax
mov eax, dword [esi + 0x1e8]
mov dword [esi + 0x1e4], eax
inc eax
test ebx, ebx
mov dword [esp + 0x64], 1
mov dword [esi + 0x1e8], eax
mov dword [esp + 0x38], ebp
je 0x49a44e
mov al, byte [ebp + 0x40]
test al, al
jne 0x49a44e
mov eax, dword [esi + 0x44]
test eax, eax
jne 0x49a44e
push 0
push 0
push 0
push 0x15
push esi
call fcn.0048cd30
add esp, 0x14
test eax, eax
jne 0x49a44e
mov ecx, 0xa
lea edi, [esp + 0x80]
rep stosd dword es:[edi], eax
mov ecx, dword [esp + 0xdc]
cmp byte [ecx], 4
ja 0x4992f1
mov edx, dword [ebx + 0x38]
push edx
push ebp
call fcn.0047d600
add esp, 8
and word [ebx + 6], 0xfffe
mov dword [ebx + 0x38], 0
push 0
push ebx
push esi
call fcn.00498460
mov eax, dword [ebx + 0x38]
mov ecx, dword [ebx + 0x28]
mov edx, dword [ebx]
mov dword [esp + 0x58], eax
mov eax, dword [esi + 0x44]
add esp, 0xc
test eax, eax
mov dword [esp + 0x40], ecx
mov dword [esp + 0x60], edx
jne 0x49a3ea
mov eax, dword [esp + 0x38]
mov cl, byte [eax + 0x40]
test cl, cl
jne 0x49a3ea
mov cl, byte [ebx + 6]
push esi
shr ecx, 2
and ecx, 1
mov dword [esp + 0x30], ecx
call fcn.004983b0
mov ebp, eax
add esp, 4
test ebp, ebp
je 0x49a3ea
mov edx, dword [esp + 0x60]
mov ecx, dword [esp + 0xdc]
mov eax, dword [edx]
push eax
push ecx
push esi
call fcn.0049a830
add esp, 0xc
test eax, eax
jne 0x49a3ea
mov dword [esp + 0x24], eax
mov eax, dword [ebx + 0x3c]
test eax, eax
jne 0x49965e
mov eax, dword [esp + 0x40]
xor edx, edx
mov dl, byte [eax]
mov eax, dword [esp + 0x24]
cmp eax, edx
jge 0x49965e
mov edx, dword [esp + 0x40]
lea ecx, [eax + eax*8]
mov eax, dword [edx + ecx*8 + 0x1c]
lea edi, [edx + ecx*8 + 8]
test eax, eax
mov dword [esp + 0x18], eax
je 0x49964a
mov eax, dword [edi + 0x18]
test eax, eax
je 0x4993cf
test byte [edi + 0x24], 4
jne 0x49964a
push eax
mov eax, dword [edi + 0x1c]
push eax
push 0xf
push ebp
call fcn.004870f0
add esp, 0x10
jmp 0x49964a
push ebx
call fcn.0049a460
mov edx, dword [esi + 0x1e0]
mov ecx, dword [esp + 0x1c]
add edx, eax
mov dword [esi + 0x1e0], edx
mov al, byte [ecx + 6]
mov edx, dword [esp + 0x30]
shr eax, 2
and eax, 1
mov dword [esp + 0x48], eax
push eax
mov eax, dword [esp + 0x2c]
push edx
push eax
push ebx
push esi
call fcn.0049ca70
add esp, 0x18
test eax, eax
je 0x49942e
mov eax, dword [esp + 0x44]
test eax, eax
je 0x499421
or byte [ebx + 6], 4
mov dword [esp + 0x2c], 1
mov dword [esp + 0x24], 0xffffffff
jmp 0x499609
mov ecx, dword [esp + 0x40]
cmp byte [ecx], 1
jne 0x49955b
mov eax, 0x100
test word [ebx + 6], ax
jne 0x49955b
mov edx, dword [esp + 0x38]
test word [edx + 0x3c], ax
jne 0x49955b
mov ecx, dword [esi + 0x4c]
push 0xffffffffffffffff
inc ecx
push esi
mov eax, ecx
mov dword [esi + 0x4c], ecx
mov dword [edi + 0x1c], eax
mov eax, dword [esi + 0x4c]
inc eax
mov dword [esi + 0x4c], eax
mov dword [esp + 0x30], eax
call fcn.00490580
push 0xe
push ebp
call fcn.0048d090
mov ecx, dword [edi + 0x2c]
push ecx
push 0x35
push ebp
call fcn.00487bd0
push 1
push ebp
mov dword [esp + 0x60], eax
call fcn.00487620
mov eax, dword [esp + 0x4c]
mov edx, dword [esp + 0x60]
push eax
push 0
push 0x15
push ebp
mov dword [edi + 0x18], edx
call fcn.004870f0
push 1
push ebp
call fcn.00487620
mov ecx, dword [edi + 0x1c]
lea edx, [esp + 0xe8]
push ecx
push 0xa
push edx
call fcn.00497bd0
mov edx, dword [esp + 0x60]
mov al, byte [esi + 0x1e8]
add esp, 0x48
lea ecx, [esp + 0xac]
mov byte [edi + 0x28], al
push ecx
push edx
push esi
call fcn.00499240
mov ecx, dword [esp + 0x24]
mov eax, dword [edi + 0x10]
mov edx, dword [ecx + 0x20]
mov ecx, dword [esp + 0x48]
mov dword [eax + 0x1c], edx
mov edx, dword [edi + 0x24]
or edx, 4
mov dword [edi + 0x24], edx
mov eax, dword [esp + 0xc0]
push eax
push ecx
push ebp
call fcn.0047a440
mov edx, dword [esp + 0xd0]
mov eax, dword [esp + 0x54]
push edx
push eax
push ebp
call fcn.0047a460
mov ecx, dword [esp + 0x4c]
push ecx
push 1
push 0x15
push ebp
call fcn.004870f0
mov edx, dword [edi + 0x1c]
push edx
push 0x11
push ebp
call fcn.00487bd0
add esp, 0x40
mov eax, dword [esp + 0x3c]
dec eax
push eax
push ebp
call fcn.00487110
push esi
call fcn.0049a820
add esp, 0xc
jmp 0x499609
mov eax, dword [esi + 0x4c]
mov dword [esp + 0x1c], 0
inc eax
push eax
push 0
push 0x15
mov dword [esi + 0x4c], eax
push ebp
mov dword [edi + 0x1c], eax
call fcn.004870f0
add esp, 0x10
mov dword [esp + 0x44], eax
inc eax
mov dword [edi + 0x18], eax
mov al, byte [edi + 0x24]
test al, 2
jne 0x499597
push esi
call fcn.004895b0
add esp, 4
mov dword [esp + 0x1c], eax
mov ecx, dword [edi + 0x2c]
lea edx, [esp + 0xac]
push ecx
push 9
push edx
call fcn.00497bd0
mov edx, dword [esp + 0x24]
mov al, byte [esi + 0x1e8]
lea ecx, [esp + 0xb8]
mov byte [edi + 0x28], al
push ecx
push edx
push esi
call fcn.00499240
mov ecx, dword [esp + 0x30]
mov eax, dword [edi + 0x10]
add esp, 0x18
mov edx, dword [ecx + 0x20]
mov dword [eax + 0x1c], edx
mov eax, dword [esp + 0x1c]
test eax, eax
je 0x4995e8
push eax
push ebp
call fcn.00487110
add esp, 8
mov ecx, dword [edi + 0x1c]
push ecx
push 0x10
push ebp
call fcn.00487bd0
mov edx, dword [esp + 0x50]
push eax
push edx
push ebp
call fcn.0047a420
push esi
call fcn.0049a820
add esp, 0x1c
mov eax, dword [esp + 0x38]
mov cl, byte [eax + 0x40]
test cl, cl
jne 0x49a3ea
push ebx
call fcn.0049a460
mov ecx, dword [esi + 0x1e0]
mov edx, dword [esp + 0xe0]
sub ecx, eax
add esp, 4
mov dword [esi + 0x1e0], ecx
mov al, byte [edx]
mov ecx, dword [ebx + 0x28]
cmp al, 4
mov dword [esp + 0x40], ecx
jbe 0x49964a
mov eax, dword [ebx + 0x38]
mov dword [esp + 0x4c], eax
mov ecx, dword [esp + 0x24]
mov eax, dword [ebx + 0x3c]
inc ecx
test eax, eax
mov dword [esp + 0x24], ecx
je 0x49937a
mov edx, dword [ebx + 0x2c]
mov eax, dword [ebx + 0x30]
mov ecx, dword [ebx]
mov dword [esp + 0x30], edx
mov dl, byte [ebx + 6]
mov dword [esp + 0x10], eax
mov eax, dword [ebx + 0x3c]
mov dword [esp + 0x60], ecx
mov ecx, dword [ebx + 0x34]
and dl, 1
test eax, eax
mov dword [esp + 0x7c], ecx
mov byte [esp + 0x6c], dl
je 0x4996f3
mov eax, dword [ebx + 0x44]
test eax, eax
jne 0x4996c9
xor ecx, ecx
xor edx, edx
mov eax, ebx
mov dword [eax + 0x40], ecx
mov dword [eax + 0x44], ebx
mov ecx, eax
mov eax, dword [eax + 0x3c]
inc edx
test eax, eax
jne 0x499697
mov eax, dword [esp + 0x38]
mov eax, dword [eax + 0x68]
test eax, eax
je 0x4996c9
cmp edx, eax
jle 0x4996c9
push str.too_many_terms_in_compound_SELECT
push esi
call fcn.0047a260
add esp, 8
jmp 0x49a3ea
mov ecx, dword [esp + 0xdc]
push ecx
push ebx
push esi
call fcn.0049b6b0
mov edx, dword [esp + 0xb4]
add esp, 0xc
mov dword [esi + 0x1e4], edx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc0
ret
mov edi, dword [esp + 0x4c]
mov eax, dword [esp + 0x10]
push 0xffffffffffffffff
push edi
push eax
call fcn.0048ca00
add esp, 0xc
test eax, eax
jne 0x49971b
mov ecx, dword [esp + 0x38]
test byte [ecx + 0x3c], 4
jne 0x49971b
xor edi, edi
mov dword [esp + 0x4c], edi
mov dl, byte [ebx + 6]
and dl, 5
cmp dl, 1
jne 0x499822
mov eax, dword [ebx]
push 0xffffffffffffffff
push eax
push edi
call fcn.0048ca00
add esp, 0xc
test eax, eax
jne 0x499822
mov ecx, dword [ebx]
mov edx, dword [esp + 0x38]
and word [ebx + 6], 0xfffe
push eax
push ecx
push edx
call fcn.0048c3a0
add esp, 0xc
xor edi, edi
mov dword [ebx + 0x30], eax
mov dword [esp + 0x10], eax
mov dword [esp + 0x4c], edi
mov dword [esp + 0x28], 0xffffffff
mov ecx, dword [esp + 0xdc]
cmp byte [ecx], 9
jne 0x49978e
mov edx, dword [esp + 0x60]
mov eax, dword [edx]
mov edx, dword [ecx + 4]
push eax
push edx
push 0x33
push ebp
call fcn.004870f0
add esp, 0x10
push ebp
call fcn.00487bf0
push eax
push ebx
mov dword [ebx + 0x20], 0xffffffff
push esi
mov dword [esp + 0xdc], eax
mov dword [ebx + 0x24], closesocket
call fcn.0049b550
mov eax, dword [ebx + 8]
add esp, 0x10
test eax, eax
jne 0x4997d4
mov eax, dword [esp + 0x28]
test eax, eax
jl 0x4997d4
push eax
push ebp
call fcn.00493dd0
add esp, 8
mov byte [eax], 0x34
or byte [ebx + 6], 0x40
test byte [ebx + 6], 1
je 0x499864
mov eax, dword [esi + 0x48]
push 0xfffffffffffffff0
mov dword [esp + 0x74], eax
inc eax
mov dword [esi + 0x48], eax
mov ecx, dword [ebx]
push ecx
push esi
call fcn.0049af40
mov edx, dword [esp + 0x7c]
add esp, 8
push eax
push 0
push 0
push edx
push 0x33
push ebp
call fcn.00486710
push 8
push ebp
mov dword [esp + 0x98], eax
call fcn.00487620
add esp, 0x24
mov byte [esp + 0x6d], 3
jmp 0x499869
test edi, edi
je 0x499764
push edi
push esi
call fcn.0049af40
mov ecx, dword [esi + 0x48]
push 0xfffffffffffffff0
mov dword [edi + 4], ecx
mov ecx, dword [esi + 0x48]
inc ecx
push eax
mov dword [esi + 0x48], ecx
mov edx, dword [edi]
mov eax, dword [edi + 4]
add edx, 2
push 0
push edx
push eax
push 0x33
push ebp
call fcn.00486710
add esp, 0x24
mov dword [esp + 0x28], eax
mov dword [ebx + 0x18], eax
jmp 0x49976c
mov byte [esp + 0x6d], 0
mov ecx, dword [esp + 0x2c]
mov edx, dword [esp + 0x10]
xor eax, eax
cmp ecx, eax
jne 0x49998c
cmp edx, eax
jne 0x49998c
mov al, byte [esp + 0x6c]
mov ecx, dword [esp + 0x30]
neg al
sbb eax, eax
mov edx, dword [esp + 0x40]
and eax, 0x400
push 0
push eax
mov eax, dword [ebx]
push eax
push edi
push ecx
push edx
push esi
call fcn.0049ffc0
add esp, 0x1c
mov dword [esp + 0x20], eax
test eax, eax
je 0x49a3ea
push eax
call fcn.0049feb0
mov ecx, dword [ebx + 0x24]
add esp, 4
cmp edx, ecx
ja 0x4998e0
jb 0x4998cd
cmp eax, dword [ebx + 0x20]
jae 0x4998e0
mov ecx, dword [esp + 0x20]
push ecx
call fcn.0049feb0
mov dword [ebx + 0x20], eax
add esp, 4
mov dword [ebx + 0x24], edx
mov al, byte [esp + 0x6c]
test al, al
je 0x49990a
mov edx, dword [esp + 0x20]
push edx
call fcn.0049ff70
add esp, 4
test eax, eax
je 0x49990a
mov eax, dword [esp + 0x20]
push eax
call fcn.0049ff70
add esp, 4
mov byte [esp + 0x6d], al
test edi, edi
je 0x499921
mov ecx, dword [esp + 0x20]
push ecx
call fcn.0049ff80
add esp, 4
test eax, eax
je 0x499921
xor edi, edi
mov eax, dword [esp + 0x28]
test eax, eax
jl 0x499940
test edi, edi
jne 0x499940
mov edx, eax
push edx
push ebp
call fcn.0047a480
add esp, 8
mov dword [ebx + 0x18], 0xffffffff
mov eax, dword [esp + 0x20]
push eax
call fcn.0049ffa0
mov ecx, dword [esp + 0x24]
add esp, 4
push eax
push ecx
call fcn.0049ff90
mov edx, dword [esp + 0xe4]
add esp, 4
mov ecx, dword [esp + 0x64]
push eax
lea eax, [esp + 0x74]
push edx
push eax
push edi
push 0
push 0
push ecx
push ebx
push esi
call fcn.0049a870
mov edx, dword [esp + 0x48]
push edx
call fcn.004a6830
add esp, 0x2c
jmp 0x49a393
cmp edx, eax
mov dword [esp + 0x50], eax
mov dword [esp + 0x48], eax
je 0x4999e5
mov eax, dword [ebx]
mov ecx, dword [eax]
mov eax, dword [eax + 8]
test ecx, ecx
jle 0x4999b1
add eax, 0x16
mov word [eax], 0
add eax, 0x18
dec ecx
jne 0x4999a6
mov ecx, dword [edx]
mov eax, dword [edx + 8]
test ecx, ecx
jle 0x4999c8
add eax, 0x16
mov word [eax], 0
add eax, 0x18
dec ecx
jne 0x4999bd
mov ecx, dword [ebx + 0x24]
mov eax, 0x64
test ecx, ecx
ja 0x4999d9
cmp dword [ebx + 0x20], eax
jbe 0x4999ef
mov dword [ebx + 0x20], eax
mov dword [ebx + 0x24], 0
jmp 0x4999ef
mov dword [ebx + 0x20], 1
mov dword [ebx + 0x24], eax
push ebp
call fcn.00487bf0
mov dword [esp + 0x40], eax
mov ecx, 8
xor eax, eax
lea edi, [esp + 0xb0]
rep stosd dword es:[edi], eax
mov eax, dword [esp + 0x44]
add esp, 4
mov dword [esp + 0xb0], eax
mov eax, dword [esp + 0x10]
lea ecx, [esp + 0x80]
mov dword [esp + 0xac], esi
test eax, eax
mov dword [esp + 0xb8], ecx
je 0x499a42
mov edx, eax
mov eax, dword [edx]
inc eax
mov dword [esp + 0x8c], eax
jmp 0x499a4d
mov dword [esp + 0x8c], 0
mov edx, dword [esp + 0x60]
mov ecx, dword [esp + 0x10]
lea eax, [esp + 0xac]
push edx
push eax
mov dword [esp + 0x98], ecx
call fcn.0049a7e0
mov ecx, dword [esp + 0x54]
lea edx, [esp + 0xb4]
push ecx
push edx
call fcn.0049a7e0
mov eax, dword [esp + 0x8c]
xor edi, edi
add esp, 0x10
cmp eax, edi
je 0x499a9d
push eax
lea eax, [esp + 0xb0]
push eax
call fcn.0049a4d0
add esp, 8
mov eax, dword [esp + 0xa4]
mov ecx, dword [esp + 0x98]
cmp eax, edi
mov dword [esp + 0x9c], ecx
mov dword [esp + 0x24], edi
jle 0x499b10
mov al, byte [esp + 0xc8]
mov edx, dword [esp + 0xa0]
or al, 8
mov byte [esp + 0xc8], al
mov eax, dword [edi + edx]
lea edx, [esp + 0xac]
mov ecx, dword [eax + 0x10]
push ecx
push edx
call fcn.0049a7e0
mov dl, byte [esp + 0xd0]
mov eax, dword [esp + 0x2c]
mov ecx, dword [esp + 0xac]
add esp, 8
and dl, 0xf7
inc eax
add edi, 0x10
cmp eax, ecx
mov byte [esp + 0xc8], dl
mov dword [esp + 0x24], eax
jl 0x499aba
mov eax, dword [esp + 0x38]
mov cl, byte [eax + 0x40]
test cl, cl
jne 0x49a3ea
mov edi, dword [esp + 0x10]
test edi, edi
je 0x49a10a
mov eax, dword [esi + 0x48]
push edi
mov dword [esp + 0x88], eax
inc eax
push esi
mov dword [esi + 0x48], eax
call fcn.0049af40
mov ecx, dword [esp + 0x94]
mov edx, dword [esp + 0x8c]
push 0xfffffffffffffff0
push eax
push 0
push ecx
push edx
push 0x34
push ebp
mov dword [esp + 0x8c], eax
call fcn.00486710
mov dword [esp + 0x9c], eax
mov eax, dword [esi + 0x4c]
inc eax
push ebp
mov dword [esp + 0x84], eax
inc eax
mov dword [esp + 0x44], eax
inc eax
mov dword [esi + 0x4c], eax
call fcn.00487bf0
mov ecx, dword [esi + 0x4c]
mov dword [esp + 0x5c], eax
inc ecx
push ebp
mov eax, ecx
mov dword [esi + 0x4c], ecx
mov dword [esp + 0x54], eax
call fcn.00487bf0
mov edx, dword [edi]
mov dword [esp + 0x80], eax
mov eax, dword [esi + 0x4c]
lea ecx, [eax + 1]
add eax, edx
mov edx, dword [esp + 0x48]
mov dword [esp + 0x70], ecx
lea ecx, [eax + 1]
mov dword [esi + 0x4c], eax
mov dword [esp + 0x84], ecx
mov ecx, dword [edi]
push edx
push 0
add eax, ecx
push 0x15
push ebp
mov dword [esi + 0x4c], eax
call fcn.004870f0
mov eax, dword [esp + 0x98]
push eax
push 0
push 0x15
push ebp
call fcn.004870f0
mov ecx, dword [edi]
mov eax, dword [esp + 0x90]
add esp, 0x4c
lea edx, [ecx + eax - 1]
push edx
push eax
push 0
push 0x18
push ebp
call fcn.00486750
mov eax, dword [esp + 0x68]
mov ecx, dword [esp + 0x3c]
push eax
push ecx
push 0xf
push ebp
call fcn.004870f0
push 0
push 0x100
push 0
push edi
mov edx, dword [esp + 0x64]
mov eax, dword [esp + 0x74]
push edx
push eax
push esi
call fcn.0049ffc0
add esp, 0x40
mov dword [esp + 0x20], eax
test eax, eax
je 0x49a3ea
mov ecx, eax
push ecx
call fcn.0049ff80
add esp, 4
test eax, eax
je 0x499c59
mov dword [esp + 0x2c], 0
jmp 0x499e5b
mov al, byte [esp + 0x6c]
test al, al
je 0x499c6c
test byte [ebx + 6], 1
mov eax, str.DISTINCT
je 0x499c71
mov eax, str.GROUP_BY
push eax
push esi
call fcn.0049afc0
mov edx, dword [esp + 0x18]
mov ecx, dword [esp + 0xa0]
add esp, 8
mov dword [esp + 0x2c], 1
mov edi, dword [edx]
mov dword [esp + 0x64], edi
inc edi
mov eax, edi
mov dword [esp + 0x18], edi
test ecx, ecx
mov dword [esp + 0x30], eax
jle 0x499cd5
mov edx, dword [esp + 0x94]
mov dword [esp + 0x30], ecx
add edx, 0xc
mov ecx, dword [edx]
cmp ecx, dword [esp + 0x18]
jl 0x499cc3
mov ecx, dword [esp + 0x18]
inc eax
inc ecx
mov dword [esp + 0x18], ecx
mov ecx, dword [esp + 0x30]
add edx, 0x18
dec ecx
mov dword [esp + 0x30], ecx
jne 0x499cb1
mov dword [esp + 0x30], eax
push eax
push esi
call fcn.0048a770
push esi
mov dword [esp + 0x54], eax
call fcn.00497670
mov edx, dword [esp + 0x54]
mov eax, dword [esp + 0x1c]
push 0
push edx
push eax
push esi
call fcn.0048a080
mov ecx, dword [esp + 0x64]
mov edx, dword [esp + 0x80]
mov eax, dword [esp + 0xa0]
add ecx, edx
push ecx
push eax
push 0x40
push ebp
call fcn.004870f0
mov eax, dword [esp + 0xc4]
add esp, 0x2c
test eax, eax
mov dword [esp + 0x18], edi
mov dword [esp + 0x24], 0
jle 0x499db8
mov ecx, dword [esp + 0x48]
mov eax, dword [esp + 0x94]
mov edx, edi
add ecx, edx
xor edi, edi
mov dword [esp + 0x50], ecx
mov ecx, dword [esp + 0x18]
mov edx, dword [edi + eax + 0xc]
cmp edx, ecx
jl 0x499da1
mov edx, dword [esp + 0x50]
mov ecx, dword [edi + eax + 4]
push 0
push edx
mov edx, dword [edi + eax + 8]
mov eax, dword [edi + eax]
push ecx
push edx
push eax
push esi
call fcn.00489e40
mov ecx, dword [esp + 0x68]
add esp, 0x18
cmp ecx, eax
je 0x499d88
push ecx
push eax
push 0x1d
push ebp
call fcn.004870f0
add esp, 0x10
mov ecx, dword [esp + 0x18]
mov eax, dword [esp + 0x50]
inc ecx
inc eax
mov dword [esp + 0x50], eax
mov eax, dword [esp + 0x94]
mov dword [esp + 0x18], ecx
mov ecx, dword [esp + 0x24]
mov edx, dword [esp + 0x98]
inc ecx
add edi, 0x18
cmp ecx, edx
mov dword [esp + 0x24], ecx
jl 0x499d49
push esi
call fcn.00487130
mov edx, dword [esp + 0x34]
mov edi, eax
mov eax, dword [esp + 0x4c]
push edi
push edx
push eax
push 0x2b
push ebp
call fcn.00486750
mov ecx, dword [esp + 0x9c]
push edi
push ecx
push 0x66
push ebp
call fcn.004870f0
push edi
push esi
call fcn.00487160
mov edx, dword [esp + 0x60]
mov eax, dword [esp + 0x78]
push edx
push eax
push esi
call fcn.0048a7a0
mov ecx, dword [esp + 0x5c]
push ecx
call fcn.004a6830
mov edi, dword [esi + 0x48]
add esp, 0x40
mov dword [esp + 0x50], edi
mov dword [esp + 0x88], edi
lea edx, [edi + 1]
push esi
mov dword [esi + 0x48], edx
call fcn.00487130
mov ecx, dword [esp + 0x34]
mov dword [esp + 0x4c], eax
push ecx
push eax
push edi
push 0x35
push ebp
call fcn.00486750
mov edx, dword [esp + 0x54]
mov eax, dword [esp + 0x9c]
push edx
push eax
push 0x63
push ebp
call fcn.004870f0
push esi
mov byte [esp + 0xad], 1
call fcn.00497670
add esp, 0x2c
push ebp
call fcn.00487c60
push esi
mov dword [esp + 0x6c], eax
call fcn.00497670
mov eax, dword [esp + 0x34]
add esp, 8
test eax, eax
je 0x499e8e
mov ecx, dword [esp + 0x48]
mov edx, dword [esp + 0x84]
push ecx
push edx
push 0x51
push ebp
call fcn.004870f0
add esp, 0x10
mov eax, dword [esp + 0x10]
xor edi, edi
cmp dword [eax], 0
jle 0x499efb
mov eax, dword [esp + 0x2c]
test eax, eax
je 0x499ecb
mov ecx, dword [esp + 0x58]
mov eax, dword [esp + 0x50]
lea edx, [edi + ecx]
push edx
push edi
push eax
push 0x29
push ebp
call fcn.00486750
add esp, 0x14
test edi, edi
jne 0x499ef2
push 0x20
push ebp
call fcn.00487620
add esp, 8
jmp 0x499ef2
mov ecx, dword [esp + 0x58]
mov byte [esp + 0x80], 1
lea eax, [edi + edi*2]
lea edx, [edi + ecx]
mov ecx, dword [esp + 0x10]
push edx
mov edx, dword [ecx + 8]
mov eax, dword [edx + eax*8]
push eax
push esi
call fcn.00487ea0
add esp, 0xc
mov ecx, dword [esp + 0x10]
inc edi
cmp edi, dword [ecx]
jl 0x499e99
mov eax, dword [esp + 0x10]
mov edx, dword [esp + 0x68]
mov edi, dword [esp + 0x44]
push 0xfffffffffffffffa
mov ecx, dword [eax]
push edx
mov edx, dword [esp + 0x60]
push ecx
push edx
push edi
push 0x24
push ebp
call fcn.00486710
push ebp
call fcn.00487c60
mov dword [esp + 0x88], eax
inc eax
push eax
push 0
push eax
push 0x25
push ebp
call fcn.00486750
mov eax, dword [esp + 0x44]
mov edx, dword [esp + 0x8c]
mov ecx, dword [eax]
push ecx
push edi
push edx
push esi
call fcn.0049a480
mov ecx, dword [esp + 0x60]
mov eax, dword [esp + 0x78]
add esp, 0x44
lea edi, [ecx + 1]
push eax
push edi
push 0xf
push ebp
call fcn.004870f0
mov edx, dword [esp + 0x4c]
mov eax, dword [esp + 0x2c]
push edx
push eax
push 0x7e
push ebp
call fcn.004870f0
mov ecx, dword [esp + 0x74]
mov edx, dword [esp + 0x48]
push ecx
push edx
push 0xf
push ebp
call fcn.004870f0
mov eax, dword [esp + 0x98]
push eax
push ebp
call fcn.00487110
lea ecx, [esp + 0xb8]
push ecx
push esi
call fcn.0049d4a0
mov edx, dword [esp + 0x9c]
add esp, 0x40
push edx
push 1
push 0x15
push ebp
call fcn.004870f0
mov eax, dword [esp + 0x3c]
add esp, 0x10
test eax, eax
je 0x499fdd
mov eax, dword [esp + 0x64]
mov ecx, dword [esp + 0x84]
push eax
push ecx
push 5
push ebp
call fcn.004870f0
add esp, 0x10
jmp 0x499ff5
mov edx, dword [esp + 0x20]
push edx
call fcn.004a6830
mov eax, dword [esp + 0x7c]
push eax
push ebp
call fcn.0047a480
add esp, 0xc
mov ecx, dword [esp + 0x34]
push ecx
push edi
push 0xf
push ebp
call fcn.004870f0
mov edx, dword [esp + 0x4c]
push edx
push 0
push 0xe
push ebp
call fcn.004870f0
push ebp
call fcn.00487c60
mov dword [esp + 0x9c], eax
mov eax, dword [esp + 0x40]
push eax
push 1
push 0x15
push ebp
call fcn.004870f0
push edi
push 0x10
push ebp
call fcn.00487bd0
mov ecx, dword [esp + 0x74]
add esp, 0x40
push ecx
push ebp
call fcn.00487c40
push ebp
call fcn.00487c60
mov edx, dword [esp + 0x68]
mov dword [esp + 0x40], eax
add eax, 2
push eax
push edx
push 0x7e
push ebp
call fcn.004870f0
push edi
push 0x10
push ebp
call fcn.00487bd0
lea eax, [esp + 0xa8]
push eax
push esi
call fcn.0049d440
mov ecx, dword [esp + 0x64]
mov edx, dword [esp + 0xac]
push 8
lea eax, [ecx + 1]
push eax
push edx
push esi
mov dword [esp + 0xa8], eax
call fcn.0048a0f0
mov eax, dword [esp + 0xb8]
mov ecx, dword [esp + 0xa8]
mov edx, dword [esp + 0x11c]
add esp, 0x40
push eax
push ecx
mov ecx, dword [esp + 0x54]
lea eax, [esp + 0x74]
push edx
mov edx, dword [ebx]
push eax
push ecx
push 0
push 0
push edx
push ebx
push esi
call fcn.0049a870
push edi
push 0x10
push ebp
call fcn.00487bd0
mov eax, dword [esp + 0x88]
push eax
push ebp
call fcn.00487c40
lea ecx, [esp + 0xbc]
push ecx
push esi
call fcn.0049d370
mov edx, dword [esp + 0x6c]
add esp, 0x44
push edx
push 0x10
push ebp
call fcn.00487bd0
mov edi, dword [esp + 0x48]
add esp, 0xc
jmp 0x49a385
lea eax, [esp + 0x80]
mov dword [esp + 0x2c], 0
push eax
push ebx
call fcn.0049d300
mov edi, eax
add esp, 8
test edi, edi
je 0x49a235
mov ecx, dword [edi + 0x40]
mov edx, dword [esi]
push ecx
push edx
call fcn.00480b60
mov ecx, dword [esi + 0x48]
push eax
mov dword [esp + 0x68], ecx
inc ecx
mov dword [esi + 0x48], ecx
xor ecx, ecx
mov dword [esp + 0x60], ecx
mov dword [esp + 0x28], ecx
mov ecx, dword [edi + 0x20]
push esi
mov dword [esp + 0x54], eax
mov dword [esp + 0x68], ecx
call fcn.00490580
mov edx, dword [edi]
mov eax, dword [edi + 0x20]
mov ecx, dword [esp + 0x54]
push edx
push 0
push eax
push ecx
push esi
call fcn.0048cde0
mov eax, dword [edi + 8]
add esp, 0x24
test eax, eax
je 0x49a1cc
mov ecx, dword [esp + 0x1c]
test byte [eax + 0x30], 4
jne 0x49a198
test ecx, ecx
je 0x49a196
mov dx, word [eax + 0x2c]
cmp dx, word [ecx + 0x2c]
jae 0x49a198
mov ecx, eax
mov eax, dword [eax + 0x14]
test eax, eax
jne 0x49a182
test ecx, ecx
mov dword [esp + 0x1c], ecx
je 0x49a1cc
mov ax, word [ecx + 0x2c]
movsx ecx, word [edi + 0x26]
cmp eax, ecx
jge 0x49a1cc
mov eax, dword [esp + 0x1c]
push eax
push esi
mov edx, dword [eax + 0x28]
mov dword [esp + 0x60], edx
call fcn.004909a0
add esp, 8
mov dword [esp + 0x54], eax
mov eax, dword [esp + 0x44]
mov ecx, dword [esp + 0x58]
mov edx, dword [esp + 0x5c]
push eax
push ecx
push edx
push 0x30
push ebp
call fcn.00486750
mov eax, dword [esp + 0x68]
add esp, 0x14
test eax, eax
je 0x49a1fc
push 0xfffffffffffffff0
push eax
push 0xffffffffffffffff
push ebp
call fcn.0047a4d0
add esp, 0x10
mov ecx, dword [esp + 0xa0]
mov eax, dword [esp + 0x5c]
mov edx, dword [ecx + 8]
push edx
push eax
push 0x2c
push ebp
call fcn.004870f0
mov ecx, dword [esp + 0x6c]
push ecx
push 0x36
push ebp
call fcn.00487bd0
mov edx, dword [esp + 0x38]
push edx
push edi
push esi
call fcn.0049d6b0
add esp, 0x28
jmp 0x49a33d
mov eax, dword [ebx + 0x34]
mov dword [esp + 0x34], 0
test eax, eax
mov byte [esp + 0x17], 0
jne 0x49a2a9
lea eax, [esp + 0x34]
lea ecx, [esp + 0x80]
push eax
push ecx
call fcn.0049d280
add esp, 8
mov byte [esp + 0x17], al
test al, al
je 0x49a2a9
mov edx, dword [esp + 0x34]
mov edi, dword [esp + 0x38]
push 0
push edx
push edi
call fcn.0048c3a0
add esp, 0xc
mov dword [esp + 0x34], eax
test eax, eax
mov dword [esp + 0x2c], eax
je 0x49a2a9
mov cl, byte [edi + 0x40]
test cl, cl
jne 0x49a2a9
mov cl, byte [esp + 0x17]
mov edx, dword [eax + 8]
cmp cl, 1
setne cl
mov byte [edx + 0xc], cl
mov eax, dword [esp + 0x34]
mov ecx, dword [eax + 8]
mov edx, dword [ecx]
mov byte [edx], 0x98
lea eax, [esp + 0x80]
push eax
push esi
call fcn.0049d370
movzx cx, byte [esp + 0x1f]
mov edx, dword [esp + 0x3c]
mov eax, dword [esp + 0x38]
push 0
push ecx
mov ecx, dword [esp + 0x50]
push 0
push edx
push eax
push ecx
push esi
call fcn.0049ffc0
mov edi, eax
add esp, 0x24
test edi, edi
jne 0x49a2f7
mov edx, dword [esp + 0x2c]
mov eax, dword [esp + 0x38]
push edx
push eax
call fcn.0047d600
add esp, 8
jmp 0x49a3ea
lea ecx, [esp + 0x80]
push ecx
push esi
call fcn.0049d4a0
push edi
call fcn.0049ff80
add esp, 0xc
test eax, eax
je 0x49a326
push edi
call fcn.0049ffa0
push eax
push 0
push 0xe
push ebp
call fcn.004870f0
add esp, 0x14
push edi
call fcn.004a6830
lea edx, [esp + 0x84]
push edx
push esi
call fcn.0049d440
add esp, 0xc
mov edi, dword [esp + 0x3c]
mov eax, dword [esp + 0x7c]
push 8
push edi
push eax
push esi
mov dword [esp + 0x5c], 0
call fcn.0048a0f0
mov ecx, dword [esp + 0xec]
mov edx, dword [ebx]
push edi
push edi
push ecx
push 0
push 0
push 0
push 0
push edx
push ebx
push esi
call fcn.0049a870
mov eax, dword [esp + 0x64]
mov ecx, dword [esp + 0x70]
push eax
push ecx
call fcn.0047d600
add esp, 0x40
push edi
push ebp
call fcn.00487c40
mov edi, dword [esp + 0x54]
add esp, 8
cmp byte [esp + 0x6d], 3
jne 0x49a3a8
push str.DISTINCT
push esi
call fcn.0049afc0
add esp, 8
test edi, edi
je 0x49a3d1
push str.ORDER_BY
push esi
call fcn.0049afc0
mov eax, dword [esp + 0x68]
mov edx, dword [esp + 0xe4]
push edx
mov ecx, dword [eax]
push ecx
push ebp
push ebx
push esi
call fcn.0049b010
add esp, 0x1c
mov edx, dword [esp + 0xcc]
push edx
push ebp
call fcn.00487c40
add esp, 8
mov dword [esp + 0x64], 0
mov edi, dword [esp + 0x64]
mov eax, dword [esp + 0xa8]
test edi, edi
mov dword [esi + 0x1e4], eax
jne 0x49a41e
mov ecx, dword [esp + 0xdc]
cmp byte [ecx], 5
jne 0x49a41e
mov edx, dword [esp + 0x60]
mov eax, dword [esp + 0x40]
push edx
push eax
push esi
call fcn.0049b330
add esp, 0xc
mov ecx, dword [esp + 0x94]
mov esi, dword [esp + 0x38]
push ecx
push esi
call fcn.004591b0
mov edx, dword [esp + 0xa8]
push edx
push esi
call fcn.004591b0
add esp, 0x10
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc0
ret
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0xc0
ret