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

Disassembly:
sub esp, 0xc0
mov eax, dword [0x10155004]
xor eax, esp
mov dword [esp + 0xbc], eax
mov eax, dword [esp + 0xc8]
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_RaiseException]
mov dword [esp + 0x24], eax
mov eax, dword [esp + 0xd0]
push ebp
mov ebp, ecx
mov dword [esp + 0x2c], eax
mov eax, dword [esp + 0xdc]
mov dword [esp + 0x40], eax
push esi
movzx ecx, word [ebp + 0x42]
mov eax, ecx
mov dword [esp + 0x34], edx
and eax, 1
mov dword [esp + 0x20], ebp
shl eax, 0x10
and ecx, 0xfe00
add eax, ecx
push edi
xor edi, edi
mov dword [esp + 0x1c], eax
mov eax, dword [0x10155c08]
mov dword [esp + 0x14], edi
mov dword [esp + 0x28], edi
mov dword [esp + 0x40], edi
test eax, eax
je 0x10038f64
push 0x28a
call eax
add esp, 4
test eax, eax
je 0x10038f64
mov dword [esp + 0x74], eax
lea eax, [esp + 0x6c]
push eax
push 3
push edi
push 0xc0000006
mov dword [esp + 0x7c], edi
mov dword [esp + 0x80], edi
call ebx
mov eax, dword [ebp + 0x20]
mov ecx, dword [eax]
mov eax, dword [ebp + 0x44]
add ecx, 0x60
mov dword [esp + 0x2c], ecx
mov dword [esp + 0x18], eax
cmp dword [ecx], eax
jae 0x1003956d
mov eax, dword [ebp + 0x48]
lea edi, [ecx + 8]
mov dword [esp + 0x44], eax
mov esi, 4
nop
mov ebx, dword [edi]
mov eax, dword [0x10155c08]
test eax, eax
je 0x10038fda
push 0x28a
call eax
add esp, 4
test eax, eax
je 0x10038fda
mov dword [esp + 0x80], eax
lea eax, [esp + 0x78]
push eax
push 3
push 0
push 0xc0000006
mov dword [esp + 0x88], 0
mov dword [esp + 0x8c], 0
call dword [sym.imp.KERNEL32.dll_RaiseException]
cmp dword [esp + 0x18], ebx
jbe 0x1003909e
mov edx, dword [esp + 0x30]
mov ecx, ebp
push 1
push esi
push dword [esp + 0x3c]
call fcn.10038d90
add esp, 0xc
mov dword [esp + 0x14], eax
test eax, eax
jne 0x10039087
mov ebx, dword [esp + 0x18]
or ecx, 0xffffffff
cmp esi, 4
cmove ecx, ebx
mov dword [edi], ecx
mov ecx, dword [0x10155c08]
test ecx, ecx
je 0x10039060
push 0x28a
call ecx
add esp, 4
test eax, eax
je 0x10039060
mov dword [esp + 0x8c], eax
lea eax, [esp + 0x84]
push eax
push 3
push 0
push 0xc0000006
mov dword [esp + 0x94], 0
mov dword [esp + 0x98], 0
call dword [sym.imp.KERNEL32.dll_RaiseException]
cmp byte [ebp + 0x2b], 0
jne 0x100390a2
mov eax, dword [ebp + 4]
push 9
push 1
push esi
mov ecx, dword [eax]
push eax
mov eax, dword [ecx + 0x38]
call eax
mov ecx, dword [ebp + 0x74]
lea eax, [esi + 8]
add esp, 0x10
btr ecx, eax
mov dword [ebp + 0x74], ecx
jmp 0x100390a2
cmp eax, 5
jne 0x1003964a
mov dword [esp + 0x18], ebx
mov dword [esp + 0x30], 0
jmp 0x100390a2
mov ebx, dword [esp + 0x18]
inc esi
add edi, 4
lea eax, [esi - 3]
cmp eax, 5
jl 0x10038f90
mov ecx, dword [esp + 0x2c]
cmp dword [ecx], ebx
jae 0x1003954e
mov edx, dword [ecx]
lea eax, [esp + 0x28]
push eax
mov ecx, ebp
call fcn.10038ac0
add esp, 4
mov ebx, eax
cmp dword [esp + 0x28], 0
mov dword [esp + 0x14], ebx
je 0x10039552
mov edx, dword [esp + 0x30]
mov ecx, ebp
push 1
push 3
push dword [esp + 0x3c]
call fcn.10038d90
mov ebx, eax
add esp, 0xc
mov dword [esp + 0x14], ebx
test ebx, ebx
jne 0x10039552
mov ecx, dword [esp + 0x2c]
mov edi, dword [esp + 0x18]
mov eax, dword [ecx]
mov dword [esp + 0x5c], eax
mov dword [ecx + 0x20], edi
mov eax, dword [0x10155c08]
test eax, eax
je 0x10039157
push 0x28a
call eax
add esp, 4
test eax, eax
je 0x10039157
mov dword [esp + 0x98], eax
lea eax, [esp + 0x90]
push eax
push 3
push ebx
push 0xc0000006
mov dword [esp + 0xa0], ebx
mov dword [esp + 0xa4], ebx
call dword [sym.imp.KERNEL32.dll_RaiseException]
mov edx, dword [esp + 0xe0]
mov ecx, dword [ebp + 8]
sar edx, 2
and edx, 3
mov dword [esp + 0xe0], edx
je 0x1003918a
mov eax, dword [ecx]
push edx
push ecx
mov eax, dword [eax + 0x14]
call eax
mov ebx, eax
add esp, 8
mov dword [esp + 0x14], ebx
test ebx, ebx
jne 0x1003941b
mov esi, dword [esp + 0x1c]
push 0
push esi
push 0
push dword [esp + 0x50]
call fcn.10128690
mov dword [esp + 0x50], eax
mov eax, dword [ebp + 4]
mov dword [esp + 0x54], edx
mov ecx, dword [eax]
test ecx, ecx
je 0x100391bf
push 0
push 0x27
push eax
mov eax, dword [ecx + 0x28]
call eax
mov eax, dword [ebp + 4]
add esp, 0xc
mov ecx, dword [eax]
lea edx, [esp + 0x60]
push edx
push eax
mov eax, dword [ecx + 0x18]
call eax
mov ebx, eax
add esp, 8
mov dword [esp + 0x14], ebx
test ebx, ebx
jne 0x1003941f
mov ebx, dword [esp + 0x64]
mov ebp, dword [esp + 0x54]
cmp ebx, ebp
jg 0x1003926c
mov esi, dword [esp + 0x50]
mov edi, dword [esp + 0x60]
jl 0x100391f9
cmp edi, esi
jae 0x1003926c
mov eax, dword [esp + 0x24]
push 0
push dword [esp + 0x20]
push 0
push dword [eax + 0x44]
call fcn.10128690
add eax, edi
adc edx, ebx
add eax, 0x10000
adc edx, 0
cmp edx, ebp
jg 0x1003924f
jl 0x10039223
cmp eax, esi
jae 0x1003924f
push 0x10144edc
push 0x103c8
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call fcn.10028790
mov ebx, 0xb
add esp, 0x14
mov dword [esp + 0x14], ebx
jmp 0x10039413
mov eax, dword [esp + 0x24]
mov eax, dword [eax + 4]
mov ecx, dword [eax]
test ecx, ecx
je 0x1003926c
lea edx, [esp + 0x50]
push edx
push 5
push eax
mov eax, dword [ecx + 0x28]
call eax
add esp, 0xc
mov ebx, dword [esp + 0x28]
mov dword [esp + 0x4c], ebx
mov ecx, dword [esp + 0x28]
or edx, 0xffffffff
mov dword [esp + 0x20], edx
mov eax, dword [ecx]
mov dword [esp + 0x58], eax
mov eax, dword [ebx + 4]
sub eax, 1
mov dword [esp + 0x3c], eax
js 0x100392fb
lea eax, [eax + eax*4]
lea eax, [eax + 5]
lea esi, [ecx + eax*4]
nop word [eax + eax]
mov eax, dword [esi - 0xc]
mov ebx, dword [esi]
cmp eax, ebx
jge 0x100392e7
mov ecx, dword [esi - 8]
mov ebp, dword [esi - 4]
lea edx, [ecx + eax*2]
movzx edi, word [edx]
mov ecx, dword [ebp + edi*4]
cmp ecx, dword [esp + 0x58]
ja 0x100392d0
inc eax
add edx, 2
mov dword [esi - 0xc], eax
cmp eax, ebx
jl 0x100392b2
mov edx, dword [esp + 0x20]
jmp 0x100392e7
mov edx, dword [esp + 0x20]
cmp ecx, edx
jae 0x100392e7
mov eax, edi
mov edx, ecx
add eax, dword [esi + 4]
mov dword [esp + 0x20], edx
mov dword [esp + 0x40], eax
mov eax, dword [esp + 0x3c]
sub esi, 0x14
dec eax
mov dword [esp + 0x3c], eax
test eax, eax
jns 0x100392a0
mov ebx, dword [esp + 0x4c]
mov eax, dword [esp + 0x28]
mov dword [eax], edx
cmp edx, 0xffffffff
je 0x1003940f
mov eax, dword [0x10155c08]
test eax, eax
je 0x10039359
push 0x28a
call eax
add esp, 4
test eax, eax
je 0x10039355
mov dword [esp + 0xa4], eax
lea eax, [esp + 0x9c]
push eax
push 3
push 0
push 0xc0000006
mov dword [esp + 0xac], 0
mov dword [esp + 0xb0], 0
call dword [sym.imp.KERNEL32.dll_RaiseException]
mov edx, dword [esp + 0x20]
mov eax, dword [esp + 0x38]
cmp dword [eax + 0x128], 0
jne 0x100393fa
mov ecx, dword [esp + 0x40]
cmp ecx, dword [esp + 0x5c]
jbe 0x10039274
cmp ecx, dword [esp + 0x18]
ja 0x10039274
cmp edx, dword [esp + 0x44]
ja 0x10039274
mov ebx, dword [esp + 0x1c]
dec ecx
mov ebp, dword [esp + 0x24]
lea eax, [ebx + 0x18]
mov esi, dword [ebp + 8]
mul ecx
mov edi, dword [esi]
add eax, 0x38
adc edx, 0
push edx
push eax
mov eax, dword [edi + 8]
push ebx
push dword [esp + 0x54]
push esi
call eax
mov ebx, eax
add esp, 0x14
mov dword [esp + 0x14], ebx
test ebx, ebx
jne 0x10039417
mov esi, dword [ebp + 4]
mov eax, dword [esp + 0x20]
push ebx
mov ebx, dword [esp + 0x20]
dec eax
mov edi, dword [esi]
push ebx
push 0
push eax
call fcn.10128690
push edx
push eax
mov eax, dword [edi + 0xc]
push ebx
push dword [esp + 0x54]
push esi
call eax
mov ebx, eax
add esp, 0x14
mov dword [esp + 0x14], ebx
test ebx, ebx
jne 0x10039417
mov ebx, dword [esp + 0x4c]
jmp 0x10039274
xor ebx, ebx
cmp byte [eax + 0x57], bl
sete bl
lea ebx, [ebx*2 + 7]
mov dword [esp + 0x14], ebx
jmp 0x10039413
mov ebx, dword [esp + 0x14]
mov ebp, dword [esp + 0x24]
mov edi, dword [esp + 0x18]
mov esi, dword [esp + 0x1c]
mov eax, dword [ebp + 4]
mov ecx, dword [eax]
test ecx, ecx
je 0x10039435
push 0
push 0x25
push eax
mov eax, dword [ecx + 0x28]
call eax
add esp, 0xc
test ebx, ebx
jne 0x1003952b
mov eax, dword [0x10155c08]
test eax, eax
je 0x1003947f
push 0x28a
call eax
add esp, 4
test eax, eax
je 0x1003947f
mov dword [esp + 0xb0], eax
lea eax, [esp + 0xa8]
push eax
push 3
push ebx
push 0xc0000006
mov dword [esp + 0xb8], ebx
mov dword [esp + 0xbc], ebx
call dword [sym.imp.KERNEL32.dll_RaiseException]
mov ecx, dword [ebp + 0x20]
mov ecx, dword [ecx]
cmp edi, dword [ecx + 0x10]
jne 0x100394da
mov ecx, dword [ebp + 4]
mov eax, esi
mul dword [ebp + 0x48]
mov esi, eax
mov eax, dword [ecx]
push edx
push esi
push ecx
mov eax, dword [eax + 0x10]
call eax
mov ebx, eax
add esp, 0xc
mov dword [esp + 0x14], ebx
test ebx, ebx
jne 0x1003952b
mov edx, dword [esp + 0xe0]
mov ecx, dword [ebp + 4]
test edx, edx
je 0x100394d4
mov eax, dword [ecx]
push edx
push ecx
mov eax, dword [eax + 0x14]
call eax
mov ebx, eax
add esp, 8
mov dword [esp + 0x14], ebx
test ebx, ebx
jne 0x1003952b
jmp 0x100394da
xor ebx, ebx
mov dword [esp + 0x14], ebx
mov eax, dword [esp + 0x2c]
mov dword [eax], edi
mov eax, dword [0x10155c08]
test eax, eax
je 0x1003952b
push 0x28a
call eax
add esp, 4
test eax, eax
je 0x1003952b
mov dword [esp + 0xbc], eax
lea eax, [esp + 0xb4]
push eax
push 3
push 0
push 0xc0000006
mov dword [esp + 0xc4], 0
mov dword [esp + 0xc8], 0
call dword [sym.imp.KERNEL32.dll_RaiseException]
cmp byte [ebp + 0x2b], 0
jne 0x10039552
mov eax, dword [ebp + 4]
push 9
push 1
push 3
mov ecx, dword [eax]
push eax
mov eax, dword [ecx + 0x38]
call eax
add esp, 0x10
and dword [ebp + 0x74], 0xfffff7ff
jmp 0x10039552
mov ebx, dword [esp + 0x14]
cmp ebx, 5
jne 0x1003955b
xor edi, edi
jmp 0x10039567
mov edi, dword [esp + 0x14]
test ebx, ebx
jne 0x1003964e
mov ebx, dword [sym.imp.KERNEL32.dll_RaiseException]
mov esi, dword [esp + 0xd4]
test esi, esi
je 0x1003964e
mov eax, dword [0x10155c08]
test eax, eax
je 0x100395c3
push 0x28a
call eax
add esp, 4
test eax, eax
je 0x100395c3
mov dword [esp + 0xc8], eax
lea eax, [esp + 0xc0]
push eax
push 3
push 0
push 0xc0000006
mov dword [esp + 0xd0], 0
mov dword [esp + 0xd4], 0
call ebx
mov eax, dword [esp + 0x2c]
mov eax, dword [eax]
cmp eax, dword [ebp + 0x44]
jae 0x100395d8
mov edi, 5
jmp 0x1003964e
cmp esi, 2
jl 0x1003964e
lea eax, [esp + 0x38]
push eax
push 4
call fcn.10028b10
mov edx, dword [esp + 0x38]
mov ecx, ebp
push 4
push 4
push dword [esp + 0x44]
call fcn.10038d90
mov edi, eax
add esp, 0x14
test edi, edi
jne 0x1003964e
cmp esi, 3
jne 0x10039627
mov edx, dword [esp + 0x38]
mov ecx, ebp
call fcn.10038e00
mov eax, dword [ebp + 8]
push edi
push edi
push eax
mov ecx, dword [eax]
mov eax, dword [ecx + 0x10]
call eax
add esp, 0xc
mov edi, eax
cmp byte [ebp + 0x2b], 0
jne 0x1003964e
mov eax, dword [ebp + 4]
push 9
push 4
push 4
mov ecx, dword [eax]
push eax
mov eax, dword [ecx + 0x38]
call eax
add esp, 0x10
and dword [ebp + 0x74], 0xffff0fff
jmp 0x1003964e
mov edi, dword [esp + 0x14]
push dword [esp + 0x28]
mov dword [ebp + 0x78], 0
call fcn.10025b30
mov ecx, dword [esp + 0xd0]
add esp, 4
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.10115f0d
add esp, 0xc0
ret