Function at 0x4f0194
Capabilities:
Get disk size

Disassembly:
push ebp
mov ebp, esp
mov ecx, 9
push 0
push 0
dec ecx
jne 0x4f019c
push ebx
push esi
push edi
mov esi, dword [ebp + 8]
add esi, 0xffffffe8
xor eax, eax
push ebp
push 0x4f0c02
push dword fs:[eax]
mov dword fs:[eax], esp
xor ebx, ebx
mov eax, dword [esi]
mov edx, dword [eax + 0x158]
mov eax, dword [esi]
call fcn.004ec4f0
mov edx, dword [esi]
mov byte [edx + 0x15c], al
mov eax, dword [esi]
mov dl, 1
call fcn.004e8f70
mov eax, dword [ebp + 8]
add eax, 0xfffffffc
mov edx, dword [esi]
mov edx, dword [edx + 0x1c8]
call fcn.00404928
mov eax, dword [esi]
cmp byte [eax + 0x1c1], 0
jne 0x4f023a
mov eax, dword [esi]
test byte [eax + 0x1f0], 2
je 0x4f0210
mov eax, dword [esi]
mov byte [eax + 0x1c1], 3
jmp 0x4f023a
mov eax, dword [esi]
cmp byte [eax + 0x15c], 0
jne 0x4f0226
mov eax, dword [esi]
test byte [eax + 0x1f0], 1
je 0x4f0231
mov eax, dword [esi]
mov byte [eax + 0x1c1], 2
jmp 0x4f023a
mov eax, dword [esi]
mov byte [eax + 0x1c1], 1
mov eax, dword [esi]
mov al, byte [eax + 0x1c1]
cmp al, 2
jb 0x4f025b
cmp al, 3
sete al
push eax
mov eax, dword [ebp + 8]
lea edx, [eax - 4]
mov eax, dword [esi]
xor ecx, ecx
call fcn.004e9c98
mov eax, dword [esi]
cmp byte [eax + 0x15c], 0
jne 0x4f0367
mov eax, dword [esi]
test byte [eax + 0x1f0], 4
je 0x4f0367
mov eax, dword [esi]
cmp byte [eax + 0x21c], 2
je 0x4f0294
mov eax, dword [esi]
cmp word [eax + 0xaa], 0
jne 0x4f0367
lea edx, [ebp - 0xc]
mov eax, dword [esi]
mov eax, dword [eax + 0x158]
call fcn.00408d00
mov eax, dword [ebp - 0xc]
movzx eax, byte [eax]
sub eax, 0x41
mov edx, dword [esi]
mov dword [edx + 0x160], eax
mov eax, dword [esi]
test byte [eax + 0x1f0], 1
je 0x4f02e7
lea edx, [ebp - 0x10]
mov eax, dword [esi]
mov eax, dword [eax + 0x150]
inc eax
call fcn.0040916c
mov ecx, dword [ebp - 0x10]
mov eax, dword [esi]
add eax, 0x20c
mov edx, 0x4f0c1c
call fcn.00404b94
jmp 0x4f0326
lea eax, [ebp - 0x14]
push eax
lea edx, [ebp - 0x18]
mov eax, dword [esi]
mov eax, dword [eax + 0x150]
add eax, 0x3e9
call fcn.0040916c
mov eax, dword [ebp - 0x18]
mov ecx, 3
mov edx, 2
call fcn.00404da0
mov ecx, dword [ebp - 0x14]
mov eax, dword [esi]
add eax, 0x20c
mov edx, 0x4f0c2c
call fcn.00404b94
mov eax, dword [esi]
call fcn.004f0ecc
sub eax, 0xfffffffe
je 0x4f034f
dec eax
jne 0x4f0367
push 1
mov ecx, 0x2aff
mov dl, 1
mov eax, dword [0x4e2610]
call fcn.004e2790
call fcn.0040426c
jmp 0x4f0367
push 0
mov ecx, 0x2aff
mov dl, 1
mov eax, dword [0x4e2610]
call fcn.004e2790
call fcn.0040426c
mov eax, dword [esi]
cmp byte [eax + 0x15c], 0
jne 0x4f037d
mov eax, dword [esi]
test byte [eax + 0x1f0], 1
je 0x4f038e
mov eax, dword [esi]
mov eax, dword [eax + 0x150]
inc eax
mov edx, dword [ebp + 8]
mov dword [edx - 0x1c], eax
jmp 0x4f03cf
lea eax, [ebp - 0x1c]
push eax
mov eax, dword [esi]
mov eax, dword [eax + 0x20c]
mov ecx, 3
mov edx, 9
call fcn.00404da0
mov eax, dword [ebp - 0x1c]
mov edx, 1
call fcn.00409288
mov edx, dword [ebp + 8]
mov dword [edx - 0x1c], eax
mov eax, dword [ebp + 8]
cmp dword [eax - 0x1c], 0
jge 0x4f03cf
mov eax, dword [ebp + 8]
mov dword [eax - 0x1c], 1
mov eax, dword [esi]
mov dl, byte [0x4f0c38]
mov byte [eax + 0x21d], dl
mov eax, dword [ebp + 8]
mov eax, dword [eax - 4]
call fcn.00409594
test al, al
je 0x4f04a5
mov eax, dword [ebp + 8]
mov eax, dword [eax - 4]
call fcn.0040952c
mov edx, dword [esi]
cmp eax, dword [edx + 0x138]
jne 0x4f045f
mov eax, dword [ebp + 8]
mov eax, dword [eax - 0x1c]
dec eax
mov edx, dword [esi]
cmp eax, dword [edx + 0x150]
jge 0x4f045f
lea eax, [ebp - 0x20]
push eax
mov eax, dword [ebp + 8]
mov eax, dword [eax - 0x1c]
mov dword [ebp - 0x28], eax
mov byte [ebp - 0x24], 0
lea edx, [ebp - 0x28]
xor ecx, ecx
mov eax, 0x2b20
call fcn.004e24c0
mov edx, dword [ebp - 0x20]
mov eax, dword [ebp + 8]
add eax, 0xffffffe0
call fcn.00404928
mov eax, dword [esi]
mov al, byte [eax + 0x21d]
or al, byte [0x4f0c3c]
mov edx, dword [esi]
mov byte [edx + 0x21d], al
jmp 0x4f0504
lea eax, [ebp - 0x2c]
push eax
mov eax, dword [ebp + 8]
mov eax, dword [eax - 4]
mov dword [ebp - 0x28], eax
mov byte [ebp - 0x24], 0xb
lea edx, [ebp - 0x28]
xor ecx, ecx
mov eax, 0x2b1f
call fcn.004e24c0
mov edx, dword [ebp - 0x2c]
mov eax, dword [ebp + 8]
add eax, 0xffffffe0
call fcn.00404928
mov eax, dword [esi]
mov al, byte [eax + 0x21d]
or al, byte [0x4f0c40]
mov edx, dword [esi]
mov byte [edx + 0x21d], al
jmp 0x4f0504
mov eax, dword [esi]
cmp byte [eax + 0x15c], 0
jne 0x4f0504
mov eax, dword [esi]
mov edx, dword [eax + 0x1ec]
mov eax, dword [eax + 0x1e8]
mov ecx, dword [esi]
sub eax, dword [ecx + 0x180]
sbb edx, dword [ecx + 0x184]
cmp edx, 0
jne 0x4f04d4
cmp eax, 0
je 0x4f04ee
mov eax, dword [esi]
mov al, byte [eax + 0x21d]
or al, byte [0x4f0c44]
mov edx, dword [esi]
mov byte [edx + 0x21d], al
jmp 0x4f0504
mov eax, dword [esi]
mov al, byte [eax + 0x21d]
or al, byte [0x4f0c48]
mov edx, dword [esi]
mov byte [edx + 0x21d], al
mov eax, dword [esi]
mov edx, dword [eax + 0xb0]
mov dword [ebp - 8], edx
mov edx, dword [eax + 0xb4]
mov dword [ebp - 4], edx
cmp word [ebp - 6], 0
je 0x4f0600
mov eax, dword [esi]
test byte [eax + 0xbb], 1
jne 0x4f0600
mov eax, dword [esi]
mov byte [eax + 0x21c], 1
mov eax, dword [ebp + 8]
mov eax, dword [eax - 4]
push eax
mov eax, dword [esi]
mov al, byte [eax + 0x21d]
push eax
mov eax, dword [esi]
add eax, 0x21c
push eax
mov eax, dword [ebp + 8]
mov ecx, dword [eax - 0x1c]
mov eax, dword [esi]
mov edx, dword [eax + 0xd0]
mov eax, dword [ebp - 4]
call dword [ebp - 8]
mov eax, dword [esi]
movzx eax, byte [eax + 0x21c]
cmp eax, 4
ja case.default.0x4f0575
jmp dword [eax*4 + 0x4f057c]
mov eax, dword [ebp + 8]
mov dword [eax - 0x24], 2
jmp 0x4f0692
mov eax, dword [ebp + 8]
mov dword [eax - 0x24], 7
jmp 0x4f0692
mov eax, dword [ebp + 8]
mov dword [eax - 0x24], 1
jmp 0x4f0692
mov eax, dword [ebp + 8]
mov dword [eax - 0x24], 1
mov eax, dword [esi]
mov al, byte [eax + 0xbb]
or al, byte [0x4f0c48]
mov edx, dword [esi]
mov byte [edx + 0xbb], al
jmp 0x4f0692
mov eax, dword [ebp + 8]
mov dword [eax - 0x24], 1
jmp 0x4f0692
mov eax, dword [ebp + 8]
mov dword [eax - 0x24], 1
jmp 0x4f0692
mov eax, dword [esi]
mov al, byte [eax + 0x21d]
and al, byte [0x4f0c4c]
mov dl, byte [0x4f0c38]
cmp dl, al
je 0x4f0688
mov eax, dword [esi]
test byte [eax + 0xbb], 1
jne 0x4f0688
mov eax, dword [esi]
cmp byte [eax + 0xe9], 0
jne 0x4f0688
push 0x10271b
mov ax, word [0x4f0c50]
push eax
lea edx, [ebp - 0x30]
mov eax, 0x2b5e
call fcn.004e23b0
mov edx, dword [ebp - 0x30]
mov eax, dword [ebp + 8]
mov ecx, dword [eax - 0x20]
mov eax, dword [esi]
call fcn.004e79b4
mov edx, dword [ebp + 8]
mov dword [edx - 0x24], eax
mov eax, dword [ebp + 8]
cmp dword [eax - 0x24], 0xa
jne 0x4f0692
mov eax, dword [esi]
mov al, byte [eax + 0xbb]
or al, byte [0x4f0c48]
mov edx, dword [esi]
mov byte [edx + 0xbb], al
mov eax, dword [ebp + 8]
mov dword [eax - 0x24], 1
jmp 0x4f0692
mov eax, dword [ebp + 8]
mov dword [eax - 0x24], 1
mov eax, dword [ebp + 8]
cmp dword [eax - 0x24], 0
je 0x4f06b8
mov eax, dword [ebp + 8]
cmp dword [eax - 0x24], 2
je 0x4f06b8
mov eax, dword [ebp + 8]
cmp dword [eax - 0x24], 7
jne 0x4f06d0
mov eax, dword [esi]
cmp byte [eax + 0x15c], 0
je 0x4f06d0
push 0
mov ecx, 0x2aff
mov dl, 1
mov eax, dword [0x4e2610]
call fcn.004e2790
call fcn.0040426c
mov eax, dword [ebp + 8]
cmp dword [eax - 0x24], 7
jne 0x4f06f3
mov eax, dword [esi]
xor edx, edx
mov dword [eax + 0x154], edx
mov eax, dword [esi]
mov byte [eax + 0x1c0], 1
mov bl, 1
jmp 0x4f0bda
mov eax, dword [ebp + 8]
mov eax, dword [eax - 4]
call fcn.0040945c
mov edi, eax
mov eax, dword [esi]
mov dword [eax + 0x1c4], edi
inc edi
jne 0x4f07d5
lea edx, [ebp - 0x34]
mov eax, 0x2b01
call fcn.004e23b0
mov edx, dword [ebp - 0x34]
mov eax, dword [ebp + 8]
add eax, 0xffffffe0
call fcn.00404928
mov eax, dword [ebp + 8]
push dword [eax - 0x20]
push 0x4f0c5c
mov eax, dword [ebp + 8]
push dword [eax - 4]
lea edx, [ebp - 0x38]
xor eax, eax
call fcn.004e2aa8
push dword [ebp - 0x38]
mov eax, dword [ebp + 8]
add eax, 0xffffffe0
mov edx, 4
call fcn.00404c08
push 0x11271c
mov ax, word [0x4f0c60]
push eax
mov eax, dword [ebp + 8]
mov ecx, dword [eax - 0x20]
mov eax, dword [esi]
xor edx, edx
call fcn.004e79b4
mov edx, dword [ebp + 8]
mov dword [edx - 0x24], eax
mov eax, dword [ebp + 8]
cmp dword [eax - 0x24], 0
jne 0x4f079a
push 1
mov ecx, 0x2afe
mov dl, 1
mov eax, dword [0x4e2610]
call fcn.004e2790
call fcn.0040426c
mov eax, dword [ebp + 8]
cmp dword [eax - 0x24], 4
je 0x4f07bb
push 0
mov ecx, 0x2aff
mov dl, 1
mov eax, dword [0x4e2610]
call fcn.004e2790
call fcn.0040426c
mov eax, dword [esi]
xor edx, edx
mov dword [eax + 0x154], edx
mov eax, dword [esi]
mov byte [eax + 0x1c0], 1
mov bl, 1
jmp 0x4f0bda
mov eax, dword [esi]
mov edx, 1
call fcn.004e9e7c
mov eax, dword [esi]
mov edx, dword [eax + 0x184]
mov eax, dword [eax + 0x180]
push edx
push eax
mov eax, dword [esi]
mov eax, dword [eax + 0x17c]
xor edx, edx
sub dword [esp], eax
sbb dword [esp + 4], edx
pop eax
pop edx
mov ecx, dword [esi]
mov dword [ecx + 0x180], eax
mov dword [ecx + 0x184], edx
mov eax, dword [esi]
mov ecx, dword [eax + 0x1b8]
test ecx, ecx
jle 0x4f0855
mov eax, ecx
cdq
push edx
push eax
mov eax, dword [esi]
mov edx, dword [eax + 0x184]
mov eax, dword [eax + 0x180]
cmp edx, dword [esp + 4]
jne 0x4f0840
cmp eax, dword [esp]
pop edx
pop eax
jbe 0x4f0855
jmp 0x4f0844
pop edx
pop eax
jle 0x4f0855
mov eax, ecx
cdq
mov ecx, dword [esi]
mov dword [ecx + 0x180], eax
mov dword [ecx + 0x184], edx
mov eax, dword [esi]
cmp dword [eax + 0x150], 0
jne 0x4f086b
mov eax, dword [esi]
cmp dword [eax + 0x188], 0
ja 0x4f087a
mov eax, dword [esi]
cmp dword [eax + 0x17c], 0
jbe 0x4f0913
mov eax, dword [ebp + 8]
add eax, 0xffffffec
push eax
mov eax, dword [ebp + 8]
add eax, 0xfffffff0
push eax
mov eax, dword [ebp + 8]
add eax, 0xfffffff4
push eax
mov eax, dword [ebp + 8]
add eax, 0xfffffff8
push eax
mov eax, dword [esi]
mov eax, dword [eax + 0x158]
call fcn.00404d40
push eax
call sub.kernel32.dll_GetDiskFreeSpaceA
test eax, eax
je 0x4f0913
mov eax, dword [esi]
mov ecx, dword [eax + 0x188]
mov eax, ecx
mov edx, dword [ebp + 8]
mov edi, dword [edx - 0xc]
xor edx, edx
div edi
test edx, edx
je 0x4f08e0
mov eax, ecx
mov edx, dword [ebp + 8]
mov ecx, dword [edx - 0xc]
xor edx, edx
div ecx
inc eax
mov edx, dword [ebp + 8]
imul dword [edx - 0xc]
mov edx, dword [esi]
mov dword [edx + 0x188], eax
mov eax, dword [esi]
mov ecx, dword [eax + 0x17c]
mov eax, ecx
mov edx, dword [ebp + 8]
mov edi, dword [edx - 0xc]
xor edx, edx
div edi
test edx, edx
je 0x4f0913
mov eax, ecx
mov edx, dword [ebp + 8]
mov ecx, dword [edx - 0xc]
xor edx, edx
div ecx
inc eax
mov edx, dword [ebp + 8]
imul dword [edx - 0xc]
mov edx, dword [esi]
mov dword [edx + 0x17c], eax
mov eax, dword [esi]
mov eax, dword [eax + 0x17c]
xor edx, edx
mov ecx, dword [esi]
sub dword [ecx + 0x180], eax
sbb dword [ecx + 0x184], edx
mov eax, dword [esi]
cmp dword [eax + 0x150], 0
jne 0x4f094e
mov eax, dword [esi]
mov eax, dword [eax + 0x188]
xor edx, edx
mov ecx, dword [esi]
sub dword [ecx + 0x180], eax
sbb dword [ecx + 0x184], edx
mov eax, dword [esi]
mov eax, dword [eax + 0x1bc]
cdq
mov ecx, dword [esi]
cmp edx, dword [ecx + 0x184]
jne 0x4f096f
cmp eax, dword [ecx + 0x180]
jbe 0x4f0b44
jmp 0x4f0975
jle 0x4f0b44
mov eax, dword [esi]
mov eax, dword [eax + 0x1c4]
call fcn.00409524
mov eax, dword [ebp + 8]
mov eax, dword [eax - 4]
call fcn.00409884
mov eax, dword [esi]
mov dword [eax + 0x1c4], 0xffffffff
mov eax, dword [esi]
mov edx, dword [eax + 0xb0]
mov dword [ebp - 8], edx
mov edx, dword [eax + 0xb4]
mov dword [ebp - 4], edx
cmp word [ebp - 6], 0
je 0x4f0aac
mov eax, dword [esi]
test byte [eax + 0x1f0], 1
je 0x4f09d4
mov eax, dword [esi]
mov eax, dword [eax + 0x150]
inc eax
mov edx, dword [ebp + 8]
mov dword [edx - 0x1c], eax
jmp 0x4f0a15
lea eax, [ebp - 0x3c]
push eax
mov eax, dword [esi]
mov eax, dword [eax + 0x20c]
mov ecx, 3
mov edx, 9
call fcn.00404da0
mov eax, dword [ebp - 0x3c]
mov edx, 1
call fcn.00409288
mov edx, dword [ebp + 8]
mov dword [edx - 0x1c], eax
mov eax, dword [ebp + 8]
cmp dword [eax - 0x1c], 0
jge 0x4f0a15
mov eax, dword [ebp + 8]
mov dword [eax - 0x1c], 1
mov eax, dword [esi]
mov byte [eax + 0x21c], 1
mov eax, dword [esi]
mov dl, byte [0x4f0c64]
mov byte [eax + 0x21d], dl
mov eax, dword [ebp + 8]
mov eax, dword [eax - 4]
push eax
mov eax, dword [esi]
mov al, byte [eax + 0x21d]
push eax
mov eax, dword [esi]
add eax, 0x21c
push eax
mov eax, dword [ebp + 8]
mov ecx, dword [eax - 0x1c]
mov eax, dword [esi]
mov edx, dword [eax + 0xd0]
mov eax, dword [ebp - 4]
call dword [ebp - 8]
mov eax, dword [esi]
mov al, byte [eax + 0x21c]
dec al
je 0x4f0a7c
dec al
je 0x4f0a88
dec al
je 0x4f0a94
dec al
jne 0x4f0aa0
mov eax, dword [ebp + 8]
mov dword [eax - 0x24], 2
jmp 0x4f0ae8
mov eax, dword [ebp + 8]
mov dword [eax - 0x24], 4
jmp 0x4f0ae8
mov eax, dword [ebp + 8]
mov dword [eax - 0x24], 4
jmp 0x4f0ae8
mov eax, dword [ebp + 8]
mov dword [eax - 0x24], 4
jmp 0x4f0ae8
mov eax, dword [ebp + 8]
mov dword [eax - 0x24], 4
jmp 0x4f0ae8
lea edx, [ebp - 0x40]
mov eax, 0x2b18
call fcn.004e23b0
mov edx, dword [ebp - 0x40]
mov eax, dword [ebp + 8]
add eax, 0xffffffe0
call fcn.00404928
push 0x11271d
mov ax, word [0x4f0c60]
push eax
mov eax, dword [ebp + 8]
mov ecx, dword [eax - 0x20]
mov eax, dword [esi]
xor edx, edx
call fcn.004e79b4
mov edx, dword [ebp + 8]
mov dword [edx - 0x24], eax
mov eax, dword [ebp + 8]
cmp dword [eax - 0x24], 0
jne 0x4f0b09
push 1
mov ecx, 0x2afe
mov dl, 1
mov eax, dword [0x4e2610]
call fcn.004e2790
call fcn.0040426c
mov eax, dword [ebp + 8]
cmp dword [eax - 0x24], 4
je 0x4f0b2a
push 0
mov ecx, 0x2aff
mov dl, 1
mov eax, dword [0x4e2610]
call fcn.004e2790
call fcn.0040426c
mov eax, dword [esi]
xor edx, edx
mov dword [eax + 0x154], edx
mov eax, dword [esi]
mov byte [eax + 0x1c0], 1
mov bl, 1
jmp 0x4f0bda
mov eax, dword [esi]
cmp byte [eax + 0x15c], 0
jne 0x4f0bda
mov eax, dword [esi]
test byte [eax + 0x1f0], 1
jne 0x4f0bda
lea eax, [ebp - 0x44]
push eax
lea edx, [ebp - 0x48]
mov eax, dword [esi]
mov eax, dword [eax + 0x150]
add eax, 0x3e9
call fcn.0040916c
mov eax, dword [ebp - 0x48]
mov ecx, 3
mov edx, 2
call fcn.00404da0
mov ecx, dword [ebp - 0x44]
mov eax, dword [esi]
add eax, 0x20c
mov edx, 0x4f0c2c
call fcn.00404b94
mov eax, dword [esi]
mov eax, dword [eax + 0x20c]
call fcn.00404d40
push eax
mov eax, dword [esi]
mov eax, dword [eax + 0x158]
call fcn.00404d40
push eax
call sub.kernel32.dll_SetVolumeLabelA
test eax, eax
jne 0x4f0bda
push 1
mov ecx, 0x2afd
mov dl, 1
mov eax, dword [0x4e2610]
call fcn.004e2790
call fcn.0040426c
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4f0c09
lea eax, [ebp - 0x48]
mov edx, 8
call fcn.004048b4
lea eax, [ebp - 0x20]
mov edx, 6
call fcn.004048b4
ret