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

Disassembly:
push 0xffffffffffffffff
push 0x5a96d3
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x220
push ebx
push ebp
push esi
mov edx, ecx
push edi
mov ecx, 0x7f
xor eax, eax
lea edi, [esp + 0x31]
mov byte [esp + 0x30], 0
mov esi, dword [edx + 4]
rep stosd dword es:[edi], eax
mov ecx, dword [esp + 0x240]
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [esp + 0x30]
push eax
push ecx
mov ecx, edx
call fcn.0048c3c0
test al, al
jne 0x48c80b
mov eax, dword [esi + 0x7c]
mov edx, dword [esi]
inc eax
lea ecx, [esp + 0x30]
push eax
push ecx
mov ecx, esi
call dword [edx + 0x90]
mov eax, dword [0x635400]
xor ebp, ebp
cmp eax, ebp
je 0x48c6a5
mov cl, byte [eax + 0x40]
test cl, cl
je 0x48c6a5
add eax, 0x250
push eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [esi + 0x78]
lea edx, [esp + 0x30]
push edx
push str._RX_
push ebp
push ecx
add eax, 0x3c
mov ecx, esp
mov dword [esp + 0x2c], esp
push eax
call sub.MFC42.DLL_CString::CString_2
mov ecx, dword [0x635400]
push str.command
push str.esms
mov edx, dword [ecx + 0x44]
push edx
call fcn.004eb7d0
mov eax, dword [0x635400]
add esp, 0x1c
mov edx, dword [eax + 0x248]
lea ecx, [eax + 0x248]
call dword [edx + 0x1c]
call fcn.0044c560
mov eax, dword [eax + 0xd0]
cmp byte [eax], 0
je 0x48c6fb
lea ecx, [esp + 0x30]
push ecx
push ecx
mov ecx, esp
mov dword [esp + 0x24], esp
push str._RX_
call sub.MFC42.DLL_CString::CString_3
mov edx, dword [esi + 0x78]
push ecx
add edx, 0x3c
mov ecx, esp
mov dword [esp + 0x20], esp
push edx
mov dword [esp + 0x248], ebp
call sub.MFC42.DLL_CString::CString_2
mov ecx, dword [0x62fc58]
mov dword [esp + 0x244], 0xffffffff
call fcn.00401140
mov eax, dword [0x62fc60]
cmp eax, ebp
je 0x48cf59
cmp dword [eax + 0x50], ebp
jle 0x48cf59
mov ebx, dword [sym.imp.MSVCRT.dll__mbsicmp]
mov ecx, dword [eax + 0x4c]
mov edi, dword [ecx + ebp*4]
test edi, edi
je 0x48c7fa
mov cl, byte [edi + 0x88]
test cl, cl
je 0x48c7fa
call fcn.0044c560
mov edx, dword [eax + 0xd0]
mov al, byte [edx + 2]
test al, al
je 0x48c7f5
mov eax, dword [edi + 0x84]
mov ecx, dword [eax - 8]
test ecx, ecx
je 0x48c7f5
mov ecx, dword [esi + 0x78]
add ecx, 0x3c
push ecx
lea ecx, [esp + 0x18]
call sub.MFC42.DLL_CString::CString_2
mov edx, dword [esp + 0x14]
mov dword [esp + 0x238], 1
mov eax, dword [edx - 8]
test eax, eax
je 0x48c7e1
mov al, byte [edi + 0x80]
test al, al
jne 0x48c7e1
mov eax, dword [esi + 0x78]
mov ecx, dword [edi + 0x84]
mov eax, dword [eax + 0x3c]
push eax
push ecx
call ebx
add esp, 8
test eax, eax
jne 0x48c7e1
lea ecx, [esp + 0x30]
push ecx
push ecx
mov ecx, esp
mov dword [esp + 0x18], esp
push str._RX_
call sub.MFC42.DLL_CString::CString_3
mov edx, dword [esi + 0x78]
push ecx
add edx, 0x3c
mov ecx, esp
mov dword [esp + 0x28], esp
push edx
mov byte [esp + 0x248], 2
call sub.MFC42.DLL_CString::CString_2
mov ecx, edi
mov byte [esp + 0x244], 1
call fcn.004024b0
lea ecx, [esp + 0x14]
mov dword [esp + 0x238], 0xffffffff
call sub.MFC42.DLL_CString::CString
mov eax, dword [0x62fc60]
mov ecx, dword [eax + 0x50]
inc ebp
cmp ebp, ecx
jl 0x48c717
jmp 0x48cf59
lea ecx, [esp + 0x2c]
call sub.MFC42.DLL_CString::CString_1
mov eax, dword [esi + 0x11c0]
mov ecx, dword [esi + 0x11bc]
push eax
push ecx
lea edx, [esp + 0x34]
push str.SELECT_COUNT_1__as_q_count_FROM__q_rec__WHERE_q_type_s__s
push edx
mov dword [esp + 0x248], 3
call sub.MFC42.DLL_CString::Format
push 0x40
call sub.MFC42.DLL_operatornew
add esp, 0x14
mov dword [esp + 0x10], eax
xor ebp, ebp
mov byte [esp + 0x238], 4
cmp eax, ebp
je 0x48c86c
push str.PNRR
mov ecx, eax
call fcn.004dc060
mov edi, eax
mov dword [esp + 0x28], edi
jmp 0x48c872
mov dword [esp + 0x28], ebp
mov edi, ebp
mov eax, dword [esp + 0x2c]
push 3
push 3
push 1
push eax
mov ecx, edi
mov byte [esp + 0x248], 3
call fcn.004dc0f0
test eax, eax
je 0x48c8ca
mov ecx, edi
call sym.ETermProxy.exe_public:_long_int___thiscall_CAdoRecordSet::GetRecordCount_void_
test eax, eax
jle 0x48c8ca
lea ecx, [esp + 0x14]
mov dword [esp + 0x14], ebp
push ecx
push str.q_count
mov ecx, edi
call sym.ETermProxy.exe_public:_int___thiscall_CAdoRecordSet::GetCollect_char_const___int__
mov eax, dword [esp + 0x14]
cmp eax, ebp
jl 0x48c8ca
cmp eax, 0x270f
jle 0x48c8c4
mov eax, 0x270f
mov dword [esi + 0x11cc], eax
mov edx, dword [esi + 0x11c0]
mov eax, dword [esi + 0x11bc]
push edx
push eax
lea ecx, [esp + 0x34]
push str.SELECT_TOP_1_id__q_data_FROM__q_rec__WHERE_q_type_s__s_ORDER_BY_ID_DESC
push ecx
call sub.MFC42.DLL_CString::Format
mov edx, dword [esp + 0x3c]
add esp, 0x10
mov ecx, edi
push 3
push 3
push 1
push edx
call fcn.004dc0f0
cmp eax, ebp
je 0x48cd60
lea ecx, [esp + 0x14]
call sub.MFC42.DLL_CString::CString_1
mov ecx, edi
mov byte [esp + 0x238], 5
call sym.ETermProxy.exe_public:_long_int___thiscall_CAdoRecordSet::GetRecordCount_void_
test eax, eax
jle 0x48cb71
lea eax, [esp + 0x1c]
mov ecx, edi
push eax
push 0x601170
mov dword [esp + 0x24], ebp
call sym.ETermProxy.exe_public:_int___thiscall_CAdoRecordSet::GetCollect_char_const___int__
lea ecx, [esp + 0x14]
push ecx
push str.q_data
mov ecx, edi
call sym.ETermProxy.exe_public:_int___thiscall_CAdoRecordSet::GetCollect_char_const___class_CString__
mov edx, dword [esp + 0x1c]
push ecx
lea eax, [esp + 0x18]
mov ecx, esp
mov dword [esp + 0x14], esp
push eax
mov dword [esi + 0x11d0], edx
mov dword [esi + 0x11d4], 1
call sub.MFC42.DLL_CString::CString_2
lea ecx, [esp + 0x28]
push esi
push ecx
call fcn.0048d800
add esp, 0xc
mov eax, dword [esp + 0x24]
mov edx, dword [esi]
push 1
push eax
mov ecx, esi
mov byte [esp + 0x240], 6
call dword [edx + 0x90]
mov eax, dword [0x635400]
cmp eax, ebp
je 0x48ca00
mov cl, byte [eax + 0x40]
test cl, cl
je 0x48ca00
add eax, 0x250
push eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov ecx, dword [esp + 0x24]
mov edx, dword [esi + 0x78]
push ecx
push str._RX_
push ebp
push ecx
add edx, 0x3c
mov ecx, esp
mov dword [esp + 0x20], esp
push edx
call sub.MFC42.DLL_CString::CString_2
mov eax, dword [0x635400]
push str.command
push str.esms
mov ecx, dword [eax + 0x44]
push ecx
call fcn.004eb7d0
mov edx, dword [0x635400]
add esp, 0x1c
mov eax, dword [edx + 0x248]
lea ecx, [edx + 0x248]
call dword [eax + 0x1c]
call fcn.0044c560
mov ecx, dword [eax + 0xd0]
cmp byte [ecx], 0
je 0x48ca54
mov edx, dword [esp + 0x24]
push edx
push ecx
mov ecx, esp
mov dword [esp + 0x18], esp
push str._RX_
call sub.MFC42.DLL_CString::CString_3
mov eax, dword [esi + 0x78]
push ecx
add eax, 0x3c
mov ecx, esp
mov dword [esp + 0x2c], esp
push eax
mov byte [esp + 0x248], 7
call sub.MFC42.DLL_CString::CString_2
mov ecx, dword [0x62fc58]
mov byte [esp + 0x244], 6
call fcn.00401140
mov eax, dword [0x62fc60]
cmp eax, ebp
je 0x48cb5b
cmp dword [eax + 0x50], ebp
jle 0x48cb5b
mov bl, 8
mov ecx, dword [eax + 0x4c]
mov edi, dword [ecx + ebp*4]
test edi, edi
je 0x48cb4b
mov cl, byte [edi + 0x88]
test cl, cl
je 0x48cb4b
call fcn.0044c560
mov edx, dword [eax + 0xd0]
mov al, byte [edx + 2]
test al, al
je 0x48cb46
mov eax, dword [edi + 0x84]
mov ecx, dword [eax - 8]
test ecx, ecx
je 0x48cb46
mov ecx, dword [esi + 0x78]
add ecx, 0x3c
push ecx
lea ecx, [esp + 0x14]
call sub.MFC42.DLL_CString::CString_2
mov edx, dword [esp + 0x10]
mov byte [esp + 0x238], bl
mov eax, dword [edx - 8]
test eax, eax
je 0x48cb35
mov al, byte [edi + 0x80]
test al, al
jne 0x48cb35
mov eax, dword [esi + 0x78]
mov ecx, dword [edi + 0x84]
mov eax, dword [eax + 0x3c]
push eax
push ecx
call dword [sym.imp.MSVCRT.dll__mbsicmp]
add esp, 8
test eax, eax
jne 0x48cb35
mov ecx, dword [esp + 0x24]
push ecx
push ecx
mov ecx, esp
mov dword [esp + 0x28], esp
push str._RX_
call sub.MFC42.DLL_CString::CString_3
mov edx, dword [esi + 0x78]
push ecx
add edx, 0x3c
mov ecx, esp
mov dword [esp + 0x24], esp
push edx
mov byte [esp + 0x248], 9
call sub.MFC42.DLL_CString::CString_2
mov ecx, edi
mov byte [esp + 0x244], bl
call fcn.004024b0
lea ecx, [esp + 0x10]
mov byte [esp + 0x238], 6
call sub.MFC42.DLL_CString::CString
mov eax, dword [0x62fc60]
mov ecx, dword [eax + 0x50]
inc ebp
cmp ebp, ecx
jl 0x48ca6c
mov edi, dword [esp + 0x28]
lea ecx, [esp + 0x24]
mov byte [esp + 0x238], 5
call sub.MFC42.DLL_CString::CString
jmp 0x48cd4a
mov ecx, dword [esi + 0x7c]
mov eax, dword [esi]
inc ecx
push ecx
push str.INTERNAL_Q_EMPTY
mov ecx, esi
call dword [eax + 0x90]
mov eax, dword [0x635400]
cmp eax, ebp
je 0x48cbef
mov cl, byte [eax + 0x40]
test cl, cl
je 0x48cbef
add eax, 0x250
push eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov edx, dword [esi + 0x78]
push str.INTERNAL_Q_EMPTY
push str._RX_
push ebp
push ecx
add edx, 0x3c
mov ecx, esp
mov dword [esp + 0x28], esp
push edx
call sub.MFC42.DLL_CString::CString_2
mov eax, dword [0x635400]
push str.command
push str.esms
mov ecx, dword [eax + 0x44]
push ecx
call fcn.004eb7d0
mov edx, dword [0x635400]
add esp, 0x1c
mov eax, dword [edx + 0x248]
lea ecx, [edx + 0x248]
call dword [eax + 0x1c]
call fcn.0044c560
mov ecx, dword [eax + 0xd0]
cmp byte [ecx], 0
je 0x48cc43
push str.INTERNAL_Q_EMPTY
push ecx
mov ecx, esp
mov dword [esp + 0x20], esp
push str._RX_
call sub.MFC42.DLL_CString::CString_3
mov edx, dword [esi + 0x78]
push ecx
add edx, 0x3c
mov ecx, esp
mov dword [esp + 0x2c], esp
push edx
mov byte [esp + 0x248], 0xa
call sub.MFC42.DLL_CString::CString_2
mov ecx, dword [0x62fc58]
mov byte [esp + 0x244], 5
call fcn.00401140
mov eax, dword [0x62fc60]
cmp eax, ebp
je 0x48cd4a
cmp dword [eax + 0x50], ebp
jle 0x48cd4a
mov bl, 0xb
mov ecx, dword [eax + 0x4c]
mov edi, dword [ecx + ebp*4]
test edi, edi
je 0x48cd3a
mov cl, byte [edi + 0x88]
test cl, cl
je 0x48cd3a
call fcn.0044c560
mov edx, dword [eax + 0xd0]
mov al, byte [edx + 2]
test al, al
je 0x48cd35
mov eax, dword [edi + 0x84]
mov ecx, dword [eax - 8]
test ecx, ecx
je 0x48cd35
mov ecx, dword [esi + 0x78]
add ecx, 0x3c
push ecx
lea ecx, [esp + 0x14]
call sub.MFC42.DLL_CString::CString_2
mov edx, dword [esp + 0x10]
mov byte [esp + 0x238], bl
mov eax, dword [edx - 8]
test eax, eax
je 0x48cd24
mov al, byte [edi + 0x80]
test al, al
jne 0x48cd24
mov eax, dword [esi + 0x78]
mov ecx, dword [edi + 0x84]
mov eax, dword [eax + 0x3c]
push eax
push ecx
call dword [sym.imp.MSVCRT.dll__mbsicmp]
add esp, 8
test eax, eax
jne 0x48cd24
push str.INTERNAL_Q_EMPTY
push ecx
mov ecx, esp
mov dword [esp + 0x20], esp
push str._RX_
call sub.MFC42.DLL_CString::CString_3
mov edx, dword [esi + 0x78]
push ecx
add edx, 0x3c
mov ecx, esp
mov dword [esp + 0x2c], esp
push edx
mov byte [esp + 0x248], 0xc
call sub.MFC42.DLL_CString::CString_2
mov ecx, edi
mov byte [esp + 0x244], bl
call fcn.004024b0
lea ecx, [esp + 0x10]
mov byte [esp + 0x238], 5
call sub.MFC42.DLL_CString::CString
mov eax, dword [0x62fc60]
mov ecx, dword [eax + 0x50]
inc ebp
cmp ebp, ecx
jl 0x48cc5b
mov edi, dword [esp + 0x28]
lea ecx, [esp + 0x14]
mov byte [esp + 0x238], 3
call sub.MFC42.DLL_CString::CString
jmp 0x48cf39
mov ecx, dword [esi + 0x7c]
mov eax, dword [esi]
inc ecx
push ecx
push 0x613e10
mov ecx, esi
call dword [eax + 0x90]
mov eax, dword [0x635400]
cmp eax, ebp
je 0x48cdde
mov cl, byte [eax + 0x40]
test cl, cl
je 0x48cdde
add eax, 0x250
push eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov edx, dword [esi + 0x78]
push 0x613e10
push str._RX_
push ebp
push ecx
add edx, 0x3c
mov ecx, esp
mov dword [esp + 0x28], esp
push edx
call sub.MFC42.DLL_CString::CString_2
mov eax, dword [0x635400]
push str.command
push str.esms
mov ecx, dword [eax + 0x44]
push ecx
call fcn.004eb7d0
mov edx, dword [0x635400]
add esp, 0x1c
mov eax, dword [edx + 0x248]
lea ecx, [edx + 0x248]
call dword [eax + 0x1c]
call fcn.0044c560
mov ecx, dword [eax + 0xd0]
cmp byte [ecx], 0
je 0x48ce32
push 0x613e10
push ecx
mov ecx, esp
mov dword [esp + 0x20], esp
push str._RX_
call sub.MFC42.DLL_CString::CString_3
mov edx, dword [esi + 0x78]
push ecx
add edx, 0x3c
mov ecx, esp
mov dword [esp + 0x2c], esp
push edx
mov byte [esp + 0x248], 0xd
call sub.MFC42.DLL_CString::CString_2
mov ecx, dword [0x62fc58]
mov byte [esp + 0x244], 3
call fcn.00401140
mov eax, dword [0x62fc60]
cmp eax, ebp
je 0x48cf39
cmp dword [eax + 0x50], ebp
jle 0x48cf39
mov bl, 0xe
mov ecx, dword [eax + 0x4c]
mov edi, dword [ecx + ebp*4]
test edi, edi
je 0x48cf29
mov cl, byte [edi + 0x88]
test cl, cl
je 0x48cf29
call fcn.0044c560
mov edx, dword [eax + 0xd0]
mov al, byte [edx + 2]
test al, al
je 0x48cf24
mov eax, dword [edi + 0x84]
mov ecx, dword [eax - 8]
test ecx, ecx
je 0x48cf24
mov ecx, dword [esi + 0x78]
add ecx, 0x3c
push ecx
lea ecx, [esp + 0x14]
call sub.MFC42.DLL_CString::CString_2
mov edx, dword [esp + 0x10]
mov byte [esp + 0x238], bl
mov eax, dword [edx - 8]
test eax, eax
je 0x48cf13
mov al, byte [edi + 0x80]
test al, al
jne 0x48cf13
mov eax, dword [esi + 0x78]
mov ecx, dword [edi + 0x84]
mov eax, dword [eax + 0x3c]
push eax
push ecx
call dword [sym.imp.MSVCRT.dll__mbsicmp]
add esp, 8
test eax, eax
jne 0x48cf13
push 0x613e10
push ecx
mov ecx, esp
mov dword [esp + 0x20], esp
push str._RX_
call sub.MFC42.DLL_CString::CString_3
mov edx, dword [esi + 0x78]
push ecx
add edx, 0x3c
mov ecx, esp
mov dword [esp + 0x2c], esp
push edx
mov byte [esp + 0x248], 0xf
call sub.MFC42.DLL_CString::CString_2
mov ecx, edi
mov byte [esp + 0x244], bl
call fcn.004024b0
lea ecx, [esp + 0x10]
mov byte [esp + 0x238], 3
call sub.MFC42.DLL_CString::CString
mov eax, dword [0x62fc60]
mov ecx, dword [eax + 0x50]
inc ebp
cmp ebp, ecx
jl 0x48ce4a
mov edi, dword [esp + 0x28]
test edi, edi
je 0x48cf45
mov eax, dword [edi]
push 1
mov ecx, edi
call dword [eax]
lea ecx, [esp + 0x2c]
mov dword [esp + 0x238], 0xffffffff
call sub.MFC42.DLL_CString::CString
mov ecx, dword [esp + 0x230]
pop edi
pop esi
pop ebp
mov al, 1
mov dword fs:[0], ecx
pop ebx
add esp, 0x22c
ret 4