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

Disassembly:
mov eax, dword [esp + 0x24]
sub esp, 0x60
test eax, eax
jne 0x1001d324
mov eax, 1
add esp, 0x60
ret
mov dword [eax], 0
mov eax, dword [esp + 0x64]
test eax, eax
je 0x1001d31b
push esi
mov esi, dword [esp + 0x6c]
test esi, esi
je 0x1001d342
cmp dword [esp + 0x70], 1
jge 0x1001d34c
mov eax, 1
pop esi
add esp, 0x60
ret
push edi
mov edi, dword [esp + 0x78]
cmp edi, 1
jge 0x1001d361
pop edi
mov eax, 1
pop esi
add esp, 0x60
ret
push ebx
push ebp
push eax
call sym.leptonlib.dll_lheapGetCount
mov ebx, eax
push esi
mov dword [esp + 0x24], ebx
call sym.leptonlib.dll_lheapGetCount
add esp, 8
cmp ebx, edi
mov ebp, eax
mov dword [esp + 0x20], ebp
jl 0x1001d762
cmp ebp, edi
jl 0x1001d762
mov esi, dword [sym.imp.MSVCR90.dll_calloc]
push 4
push ebx
call esi
push 4
push ebp
mov dword [esp + 0x34], eax
call esi
push 4
push ebx
mov dword [esp + 0x40], eax
call esi
push 4
push ebp
mov dword [esp + 0x4c], eax
call esi
push 4
push ebx
mov dword [esp + 0x58], eax
call esi
push 4
push ebp
mov dword [esp + 0x48], eax
call esi
add esp, 0x30
xor edi, edi
mov dword [esp + 0x34], eax
test ebx, ebx
jle 0x1001d454
mov esi, dword [esp + 0x18]
mov ebx, dword [esp + 0x2c]
mov ebp, dword [esp + 0x24]
sub ebx, esi
sub ebp, esi
mov eax, dword [esp + 0x74]
push 2
push edi
push eax
call sym.leptonlib.dll_numaaGetNuma
lea ecx, [ebx + esi]
push ecx
push 0
push eax
mov dword [esp + 0x28], eax
call sym.leptonlib.dll_numaGetIValue
mov edx, dword [esp + 0x28]
push esi
push 1
push edx
call sym.leptonlib.dll_numaGetIValue
mov eax, dword [esp + 0x34]
push eax
call sym.leptonlib.dll_lheapGetCount
dec eax
cdq
sub eax, edx
sar eax, 1
add esp, 0x28
cmp eax, dword [esp + 0x7c]
jl 0x1001d431
mov dword [esi + ebp], 1
lea ecx, [esp + 0x10]
push ecx
call sym.leptonlib.dll_numaDestroy
inc edi
add esp, 4
add esi, 4
cmp edi, dword [esp + 0x1c]
jl 0x1001d3e7
mov eax, dword [esp + 0x34]
mov ebp, dword [esp + 0x20]
mov ebx, dword [esp + 0x1c]
xor edi, edi
test ebp, ebp
jle 0x1001d4d1
mov ebx, dword [esp + 0x30]
mov ebp, dword [esp + 0x28]
sub ebx, eax
mov esi, eax
sub ebp, eax
mov edx, dword [esp + 0x78]
push 2
push edi
push edx
call sym.leptonlib.dll_numaaGetNuma
lea ecx, [ebx + esi]
push ecx
push 0
push eax
mov dword [esp + 0x2c], eax
call sym.leptonlib.dll_numaGetIValue
mov edx, dword [esp + 0x2c]
push esi
push 1
push edx
call sym.leptonlib.dll_numaGetIValue
mov eax, dword [esp + 0x38]
push eax
call sym.leptonlib.dll_lheapGetCount
dec eax
cdq
sub eax, edx
sar eax, 1
add esp, 0x28
cmp eax, dword [esp + 0x7c]
jl 0x1001d4b2
mov dword [esi + ebp], 1
lea ecx, [esp + 0x14]
push ecx
call sym.leptonlib.dll_numaDestroy
inc edi
add esp, 4
add esi, 4
cmp edi, dword [esp + 0x20]
jl 0x1001d468
mov ebp, dword [esp + 0x20]
mov ebx, dword [esp + 0x1c]
push 0
call sym.leptonlib.dll_numaCreate
push 0
mov dword [esp + 0x40], eax
call sym.leptonlib.dll_numaCreate
push 0
mov dword [esp + 0x48], eax
call sym.leptonlib.dll_numaCreate
push 0
mov dword [esp + 0x50], eax
call sym.leptonlib.dll_numaCreate
mov dword [esp + 0x54], eax
xor eax, eax
add esp, 0x10
mov dword [esp + 0x20], eax
test ebx, ebx
jle 0x1001d6c1
mov esi, dword [esp + 0x2c]
mov edx, dword [esp + 0x24]
mov ecx, dword [esp + 0x18]
sub edx, esi
sub ecx, esi
mov dword [esp + 0x4c], esi
mov dword [esp + 0x68], edx
mov dword [esp + 0x6c], ecx
lea ebx, [ebx]
cmp dword [edx + esi], 0
je 0x1001d6ad
mov edx, dword [esi]
mov ebx, dword [ecx + esi]
push 2
push eax
mov eax, dword [esp + 0x7c]
push eax
mov dword [esp + 0x60], edx
mov dword [esp + 0x70], ebx
call sym.leptonlib.dll_numaaGetNuma
xor edi, edi
add esp, 0xc
mov dword [esp + 0x10], eax
mov dword [esp + 0x48], edi
test ebp, ebp
jle 0x1001d690
mov esi, dword [esp + 0x30]
mov ecx, dword [esp + 0x28]
mov eax, dword [esp + 0x34]
sub ecx, esi
sub eax, esi
mov dword [esp + 0x50], ecx
mov dword [esp + 0x58], eax
jmp 0x1001d594
mov ecx, dword [esp + 0x50]
cmp dword [ecx + esi], 0
je 0x1001d67c
mov edx, dword [esp + 0x54]
mov eax, dword [esi]
mov ecx, edx
sub ecx, eax
mov dword [esp + 0x60], ecx
jns 0x1001d5b2
sub eax, edx
jmp 0x1001d5b4
mov eax, ecx
cmp eax, dword [esp + 0x88]
jg 0x1001d67c
mov ecx, dword [esp + 0x58]
mov eax, dword [ecx + esi]
mov ecx, ebx
sub ecx, eax
jns 0x1001d5d2
sub eax, ebx
jmp 0x1001d5d4
mov eax, ecx
cmp eax, dword [esp + 0x84]
jg 0x1001d67c
mov edx, dword [esp + 0x78]
push 2
mov ebx, ecx
push edi
push edx
mov dword [esp + 0x68], ebx
call sym.leptonlib.dll_numaaGetNuma
mov ecx, dword [esp + 0x88]
mov edx, dword [esp + 0x98]
push ecx
push edx
push eax
mov dword [esp + 0x2c], eax
mov eax, dword [esp + 0x28]
push eax
call fcn.1001cce0
add esp, 0x1c
test eax, eax
je 0x1001d66b
fild dword [esp + 0x20]
push ecx
mov ecx, dword [esp + 0x3c]
fstp dword [esp]
push ecx
call sym.leptonlib.dll_numaAddNumber
fild dword [esp + 0x50]
mov edx, dword [esp + 0x44]
add esp, 4
fstp dword [esp]
push edx
call sym.leptonlib.dll_numaAddNumber
fild dword [esp + 0x64]
mov eax, dword [esp + 0x48]
add esp, 4
fstp dword [esp]
push eax
call sym.leptonlib.dll_numaAddNumber
fild dword [esp + 0x68]
mov ecx, dword [esp + 0x4c]
add esp, 4
fstp dword [esp]
push ecx
call sym.leptonlib.dll_numaAddNumber
add esp, 8
lea edx, [esp + 0x14]
push edx
call sym.leptonlib.dll_numaDestroy
mov ebx, dword [esp + 0x68]
add esp, 4
inc edi
add esi, 4
cmp edi, ebp
mov dword [esp + 0x48], edi
jl 0x1001d590
mov esi, dword [esp + 0x4c]
lea eax, [esp + 0x10]
push eax
call sym.leptonlib.dll_numaDestroy
mov ebx, dword [esp + 0x20]
mov eax, dword [esp + 0x24]
mov edx, dword [esp + 0x6c]
mov ecx, dword [esp + 0x70]
add esp, 4
inc eax
add esi, 4
cmp eax, ebx
mov dword [esp + 0x20], eax
mov dword [esp + 0x4c], esi
jl 0x1001d530
mov ecx, dword [esp + 0x98]
mov edx, dword [esp + 0x94]
mov eax, dword [esp + 0x80]
push ecx
mov ecx, dword [esp + 0x94]
push edx
mov edx, dword [esp + 0x94]
push eax
mov eax, dword [esp + 0x48]
push ecx
mov ecx, dword [esp + 0x50]
push edx
mov edx, dword [esp + 0x4c]
push ebp
push ebx
push eax
mov eax, dword [esp + 0x64]
call fcn.1001d060
mov ecx, dword [esp + 0x44]
mov esi, dword [sym.imp.MSVCR90.dll_free]
push ecx
call esi
mov edx, dword [esp + 0x4c]
push edx
call esi
mov eax, dword [esp + 0x54]
push eax
call esi
mov ecx, dword [esp + 0x5c]
push ecx
call esi
mov edx, dword [esp + 0x48]
push edx
call esi
mov eax, dword [esp + 0x68]
push eax
call esi
lea ecx, [esp + 0x70]
push ecx
call sym.leptonlib.dll_numaDestroy
lea edx, [esp + 0x78]
push edx
call sym.leptonlib.dll_numaDestroy
lea eax, [esp + 0x80]
add esp, 0x40
push eax
call sym.leptonlib.dll_numaDestroy
lea ecx, [esp + 0x48]
push ecx
call sym.leptonlib.dll_numaDestroy
add esp, 8
pop ebp
pop ebx
pop edi
xor eax, eax
pop esi
add esp, 0x60
ret