Function at 0x10029e50
Capabilities:
Get memory capacity

Disassembly:
sub esp, 0x58
push ebx
push ebp
push esi
push edi
mov edi, ecx
mov eax, dword [edi + 0x14]
push eax
call fcn.10037f20
add esp, 4
lea ecx, [esp + 0x28]
push ecx
mov ebx, eax
mov dword [esp + 0x2c], 0x40
call dword [sym.imp.KERNEL32.dll_GlobalMemoryStatusEx]
xor edx, edx
mov eax, 0x8000000
div ebx
mov edx, dword [esp + 0x3c]
mov esi, dword [edi + 8]
push 0
push ebx
push edx
mov ebp, eax
mov eax, dword [esp + 0x44]
push eax
call sub.ntdll.dll__aulldiv
xor ecx, ecx
cmp edx, ecx
jl 0x10029eb0
jg 0x10029ea9
lea ecx, [esi + ebp]
cmp eax, ecx
jb 0x10029eb0
mov ecx, 1
jmp 0x10029eb2
xor ecx, ecx
mov eax, dword [edi + 0x10]
cmp eax, 2
je 0x1002a05d
cmp eax, 3
je 0x1002a05d
test ecx, ecx
jne 0x1002a05d
cmp esi, ebp
jb 0x1002a05d
test eax, eax
jne 0x1002a028
mov eax, dword [esp + 0x70]
add eax, eax
add eax, eax
xor edx, edx
div ebx
xor edx, edx
mov ebp, dword [esp + 0x6c]
mov esi, 0x100000
mov ecx, eax
add eax, dword [edi]
adc edx, dword [edi + 4]
mov dword [esp + 0x20], eax
mov dword [esp + 0x24], edx
xor edx, edx
mov eax, 0x400000
div ebx
mov dword [ebp + 0xc], eax
mov eax, dword [edi + 0xc]
add eax, 2
cmp eax, esi
jae 0x10029f23
mov edx, dword [edi + 8]
mov esi, eax
mov dword [ebp + 0xc], edx
mov eax, dword [ebp + 0xc]
imul ecx, ebx
imul eax, ebx
push 4
push 0x1000
push eax
shr ecx, 2
push 0
mov dword [ebp + 4], esi
mov dword [ebp], ecx
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
test eax, eax
mov dword [ebp + 8], eax
jne 0x10029f88
call fcn.10059c60
mov ebx, eax
mov esi, dword [ebx]
push 0x176
mov ecx, str...cluslist.cpp
add esi, 8
call fcn.100299b0
mov ecx, dword [esi]
push eax
push str._s:_No_sufficient_memory.
push ebx
call ecx
add esp, 0x10
mov dword [edi + 0x40], 0x15
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x58
ret 8
mov edx, dword [ebp + 0xc]
imul edx, ebx
push edx
push 0
push eax
call sub.ntdll.dll_memset
mov esi, dword [edi + 0x14]
add esp, 0xc
call fcn.10010d10
mov esi, eax
cmp esi, 0xffffffff
jne 0x10029fec
call fcn.10059c60
mov ebx, eax
mov eax, dword [edi + 0x14]
mov esi, dword [ebx]
push eax
push 0x180
mov ecx, str...cluslist.cpp
add esi, 8
call fcn.100299b0
mov ecx, dword [esi]
add esp, 4
push eax
push str._s:_Failed_to_open_DISK__d_.
push ebx
call ecx
add esp, 0x10
mov dword [edi + 0x40], 0x16
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x58
ret 8
mov edx, dword [ebp + 0xc]
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x20]
push 0
push edx
mov edx, dword [ebp + 8]
push eax
push ecx
push edx
mov eax, esi
call fcn.10029b20
add esp, 0x14
test eax, eax
push esi
jne 0x1002a27e
call dword [sym.imp.KERNEL32.dll_CloseHandle]
call fcn.10059c60
push 0x18a
jmp 0x1002a247
call fcn.10059c60
mov edi, eax
mov esi, dword [edi]
push 0x195
mov ecx, str...cluslist.cpp
add esi, 8
call fcn.100299b0
mov ecx, dword [esi]
push eax
push str._s:_The_file_system_type_invalid.
push edi
call ecx
add esp, 0x10
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x58
ret 8
mov edx, dword [edi + 0xc]
mov ebp, dword [esp + 0x6c]
add edx, 2
mov dword [ebp + 4], edx
mov dword [ebp], 0
mov eax, dword [edi + 8]
mov dword [ebp + 0xc], eax
imul eax, ebx
push 4
push 0x1000
push eax
push 0
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
test eax, eax
mov dword [ebp + 8], eax
jne 0x1002a0cd
call fcn.10059c60
mov ebx, eax
mov esi, dword [ebx]
push 0x12c
mov ecx, str...cluslist.cpp
add esi, 8
call fcn.100299b0
push eax
mov eax, dword [esi]
push str._s:_No_sufficient_memory.
push ebx
call eax
add esp, 0x10
mov dword [edi + 0x40], 0x15
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x58
ret 8
mov ecx, dword [ebp + 0xc]
imul ecx, ebx
push ecx
push 0
push eax
call sub.ntdll.dll_memset
mov esi, dword [edi + 0x14]
add esp, 0xc
call fcn.10010d10
mov ecx, eax
cmp ecx, 0xffffffff
mov dword [esp + 0x6c], ecx
jne 0x1002a12e
call fcn.10059c60
mov edx, dword [edi + 0x14]
mov ebx, eax
mov esi, dword [ebx]
push edx
push 0x136
mov ecx, str...cluslist.cpp
add esi, 8
call fcn.100299b0
add esp, 4
push eax
mov eax, dword [esi]
push str._s:_Failed_to_open_DISK__d_.
push ebx
call eax
add esp, 0x10
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x58
ret 8
xor edx, edx
mov eax, 0x800000
div ebx
xor edx, edx
mov dword [esp + 0x14], 0
mov esi, eax
mov eax, dword [ebp + 0xc]
div esi
test eax, eax
mov dword [esp + 0x20], edx
mov dword [esp + 0x18], eax
jbe 0x1002a1b9
xor eax, eax
mov dword [esp + 0x70], eax
mov dword [esp + 0x10], eax
mov eax, esi
imul eax, ebx
mov dword [esp + 0x1c], eax
mov edx, dword [esp + 0x70]
xor eax, eax
add edx, dword [edi]
push eax
adc eax, dword [edi + 4]
push esi
push eax
push edx
mov edx, dword [ebp + 8]
add edx, dword [esp + 0x20]
mov eax, ecx
push edx
call fcn.10029b20
add esp, 0x14
test eax, eax
je 0x1002a232
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x1c]
add dword [esp + 0x10], ecx
add dword [esp + 0x70], esi
mov ecx, dword [esp + 0x6c]
add eax, 1
cmp eax, dword [esp + 0x18]
mov dword [esp + 0x14], eax
jb 0x1002a167
mov edx, dword [esp + 0x20]
mov eax, dword [esp + 0x18]
test edx, edx
jbe 0x1002a27d
imul eax, esi
push 0
push edx
mov edx, eax
xor esi, esi
add edx, dword [edi]
adc esi, dword [edi + 4]
imul eax, ebx
add eax, dword [ebp + 8]
push esi
push edx
push eax
mov eax, ecx
call fcn.10029b20
add esp, 0x14
test eax, eax
jne 0x1002a279
mov eax, dword [esp + 0x6c]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
call fcn.10059c60
mov ebx, eax
mov esi, dword [ebx]
push 0x152
mov ecx, str...cluslist.cpp
add esi, 8
call fcn.100299b0
mov ecx, dword [esi]
push eax
push str._s:_Failed_to_read_sector_
push ebx
call ecx
add esp, 0x10
mov dword [edi + 0x40], 0x21
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x58
ret 8
mov edx, dword [esp + 0x6c]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
call fcn.10059c60
push 0x144
mov ebx, eax
mov esi, dword [ebx]
mov ecx, str...cluslist.cpp
add esi, 8
call fcn.100299b0
push eax
mov eax, dword [esi]
push str._s:_Failed_to_read_sector_
push ebx
call eax
add esp, 0x10
mov dword [edi + 0x40], 0x21
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x58
ret 8
mov ecx, dword [esp + 0x6c]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x58
ret 8