Function at 0x405640
Capabilities:
Get disk size

Disassembly:
sub esp, 0x134
mov eax, dword [0x421fbc]
xor eax, esp
mov dword [esp + 0x130], eax
test byte [0x442a58], 1
push ebx
mov ebx, dword [esp + 0x13c]
push esi
mov esi, dword [sym.imp.GDI32.dll_CreateSolidBrush]
mov dword [esp + 0x14], ebx
jne 0x405683
or dword [0x442a58], 1
push 0xa0a0ff
call esi
mov dword [0x442a54], eax
test byte [0x442a58], 2
jne 0x40569f
or dword [0x442a58], 2
push 0xd0d0d0
call esi
mov dword [0x442a50], eax
cmp dword [esp + 0x144], 0xc8
jne 0x4056e5
push 2
mov ecx, 0x438750
call fcn.00404250
push 0xc8
push ebx
mov dword [0x442a44], 0
call dword [sym.imp.USER32.dll_KillTimer]
pop esi
pop ebx
mov ecx, dword [esp + 0x130]
xor ecx, esp
call fcn.0040a66a
add esp, 0x134
ret
lea eax, [esp + 0x24]
push eax
call dword [sym.imp.KERNEL32.dll_GetLocalTime]
movzx ecx, word [esp + 0x24]
movzx edx, word [esp + 0x26]
movzx eax, word [esp + 0x2a]
sub ecx, 0x7d0
push ecx
push edx
push eax
lea ecx, [esp + 0x44]
push str._02d._02d._02d
push ecx
call fcn.0040ab25
add esp, 0x14
lea edx, [esp + 0x38]
push edx
push 0x3ef
mov ecx, 0x4233a8
call fcn.00404400
movzx eax, word [esp + 0x30]
movzx ecx, word [esp + 0x2e]
movzx edx, word [esp + 0x2c]
push eax
push ecx
push edx
lea eax, [esp + 0x44]
push 0x41c7b0
push eax
call fcn.0040ab25
add esp, 0x14
lea ecx, [esp + 0x38]
push ecx
push 0x3f0
mov ecx, 0x4233a8
call fcn.00404400
lea edx, [esp + 0x34]
push edx
lea eax, [esp + 0x1c]
push eax
mov eax, dword [0x4429d4]
lea ecx, [esp + 0x28]
push ecx
lea edx, [esp + 0x28]
push edx
add eax, 0x314
push eax
call dword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceA]
mov ecx, dword [esp + 0x1c]
imul ecx, dword [esp + 0x20]
test ecx, ecx
mov dword [esp + 8], ecx
fild dword [esp + 8]
jge 0x4057a6
fadd qword [0x41c7a8]
mov edx, dword [esp + 0x18]
fild dword [esp + 0x18]
test edx, edx
jge 0x4057b8
fadd qword [0x41c7a8]
mov eax, dword [0x4429ec]
fmulp st(1)
test eax, eax
fst qword [0x4429d8]
je 0x4057d5
fstp qword [eax + 0x11a08]
fld qword [0x4429d8]
lea eax, [esp + 0x38]
push eax
sub esp, 8
fstp qword [esp]
call fcn.004055c0
add esp, 0xc
lea ecx, [esp + 0x38]
push ecx
push 0x3f7
mov ecx, 0x4233a8
call fcn.00404400
mov eax, dword [0x4429d0]
fld qword [eax + 0x88]
lea edx, [esp + 0x38]
push edx
sub esp, 8
fstp qword [esp]
call fcn.004055c0
add esp, 0xc
lea ecx, [esp + 0x38]
push ecx
push 0x3f6
mov ecx, 0x4233a8
call fcn.00404400
push 0
push 0x66
push 0x400
push ebx
call dword [sym.imp.USER32.dll_SendMessageA]
xor eax, eax
mov cl, byte [eax + 0x4428c8]
mov byte [esp + eax + 0x38], cl
add eax, 1
test cl, cl
jne 0x405840
mov edx, dword [0x4429d4]
cmp dword [edx + 0xa54], 0
mov eax, 0x41c7a4
jne 0x40586a
mov eax, 0x41c6ea
mov edx, eax
lea esp, [esp]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x405870
push edi
lea edi, [esp + 0x3c]
sub eax, edx
add edi, 0xffffffff
mov cl, byte [edi + 1]
add edi, 1
test cl, cl
jne 0x405883
mov ecx, eax
shr ecx, 2
mov esi, edx
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
lea eax, [esp + 0x3c]
push eax
and ecx, 3
push ebx
rep movsb byte es:[edi], byte [esi]
call dword [sym.imp.USER32.dll_SetWindowTextA]
mov ecx, dword [0x4429d4]
cmp dword [ecx + 0xa54], 0
je 0x4058fc
push 0xff
lea edx, [esp + 0x40]
push edx
push 1
push ebx
call dword [sym.imp.USER32.dll_GetDlgItemTextA]
lea edi, [esp + 0x3c]
mov esi, 0x41c798
mov ecx, 0xc
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
je 0x4058f0
push 0x41c78c
push 1
mov ecx, 0x438750
call fcn.00404400
push 2
mov ecx, 0x438750
call fcn.004042c0
push 0
push 0
push pe_nt_image_headers32
push 0x43f
push ebx
call dword [sym.imp.USER32.dll_SendDlgItemMessageA]
cmp eax, 1
jne 0x405922
push 2
mov ecx, 0x438750
call fcn.004042c0
mov eax, dword [0x442948]
test eax, eax
push ebp
je 0x405aa8
lea ecx, [eax + 0x724]
test ecx, ecx
je 0x405aa8
xor esi, esi
cmp dword [0x4429e4], esi
jle 0x405aa8
mov ebp, dword [sym.imp.USER32.dll_GetSysColor]
mov ebx, dword [sym.imp.USER32.dll_GetSysColorBrush]
mov edi, 0x884
sub edi, 0x4210ec
mov dword [esp + 0x10], edi
jmp 0x405975
mov eax, dword [0x442948]
mov ecx, dword [0x4429d4]
cmp byte [ecx + esi + 0x438], 0
jne 0x4059cf
push 0xf
call ebp
mov ecx, dword [esi*4 + 0x4210ec]
push eax
push ecx
mov ecx, 0x4233a8
call fcn.00404660
push 0xf
call ebx
mov edx, dword [esi*4 + 0x4210ec]
push eax
push edx
mov ecx, 0x4233a8
call fcn.00401340
mov eax, dword [esi*4 + 0x4210ec]
push 0x41c788
push eax
mov ecx, 0x4233a8
call fcn.00404400
jmp 0x405a95
test eax, eax
je 0x4059da
add eax, 0x724
jmp 0x4059dc
xor eax, eax
fld dword [eax + esi*4]
lea edi, [edi + esi*4 + 0x4210ec]
fstp dword [esp + 0x14]
fld dword [esp + 0x14]
fabs
fstp dword [esp + 0x18]
fld dword [esp + 0x18]
fld dword [edi + ecx - 0x46c]
fcompp
fnstsw ax
test ah, 5
jp 0x405a19
mov ecx, dword [0x442a54]
mov edx, dword [esi*4 + 0x4210ec]
push ecx
push edx
jmp 0x405a27
mov eax, dword [0x442a50]
mov ecx, dword [esi*4 + 0x4210ec]
push eax
push ecx
mov ecx, 0x4233a8
call fcn.00401340
fld dword [esp + 0x14]
sub esp, 0xc
fst qword [esp + 4]
fstp dword [esp]
call fcn.004054d0
add esp, 4
push eax
lea edx, [esp + 0x4c]
push edx
call fcn.0040ab25
mov ecx, dword [0x442948]
xor eax, eax
add esp, 0x10
cmp dword [edi + ecx], eax
je 0x405a67
mov eax, 0xc0
mov edx, dword [esi*4 + 0x4210ec]
push eax
push edx
mov ecx, 0x4233a8
call fcn.00404660
mov ecx, dword [esi*4 + 0x4210ec]
lea eax, [esp + 0x40]
push eax
push ecx
mov ecx, 0x4233a8
call fcn.00404400
mov edi, dword [esp + 0x10]
add esi, 1
cmp esi, dword [0x4429e4]
jl 0x405970
mov ebx, dword [esp + 0x1c]
push 0
push 0
push pe_nt_image_headers32
push 0x449
push ebx
call dword [sym.imp.USER32.dll_SendDlgItemMessageA]
cmp eax, 1
mov eax, dword [0x442948]
jne 0x405ad2
or word [eax + 0x85e], 0x80
jmp 0x405adb
and word [eax + 0x85e], 0xff7f
mov ebp, dword [0x442948]
cmp dword [ebp + 0x31c], 3
jb 0x405c7b
test byte [ebp + 0x85c], 0x40
jne 0x405b58
mov eax, dword [0x442a4c]
add eax, 1
cmp eax, 4
mov dword [0x442a4c], eax
jg 0x405b82
cdq
sub eax, edx
sar eax, 1
mov edx, 2
sub edx, eax
push edx
lea eax, [esp + 0x44]
push 0x41c780
push eax
call fcn.0040ab25
add esp, 0xc
push 0xff
push 0x3f8
mov ecx, 0x4233a8
call fcn.00404660
lea ecx, [esp + 0x40]
push ecx
push 0x3f8
mov ecx, 0x4233a8
call fcn.00404400
mov ebp, dword [0x442948]
jmp 0x405b62
mov dword [0x442a4c], 0
mov dl, byte [ebp + 0x85c]
and dl, 0x3c
cmp dl, 0x3c
jne 0x405bde
mov eax, dword [0x442a48]
add eax, 1
cmp eax, 0x3c
mov dword [0x442a48], eax
jle 0x405ba1
push str.shutdown__s
call fcn.0040b485
add esp, 4
push 0
push 0
push 0x10
push ebx
call dword [sym.imp.USER32.dll_SendMessageA]
jmp 0x405c7b
cdq
sub eax, edx
sar eax, 1
mov ecx, 0x1e
sub ecx, eax
push ecx
lea edx, [esp + 0x44]
push 0x41c780
push edx
call fcn.0040ab25
add esp, 0xc
push 0xff
push 0x3f8
mov ecx, 0x4233a8
call fcn.00404660
lea eax, [esp + 0x40]
push eax
jmp 0x405c6c
mov bx, word [0x41c770]
xor edx, edx
mov dword [0x442a48], edx
mov byte [esp + 0x40], dl
xor esi, esi
lea ecx, [edx + 2]
mov eax, 1
shl eax, cl
movzx ecx, word [ebp + 0x85c]
lea edi, [esp + 0x40]
add edi, 0xffffffff
test ecx, eax
jne 0x405c22
nop
mov al, byte [edi + 1]
add edi, 1
test al, al
jne 0x405c10
mov word [edi], bx
add esi, 1
jmp 0x405c35
mov al, byte [edi + 1]
add edi, 1
test al, al
jne 0x405c22
mov ax, word [0x41c308]
mov word [edi], ax
add edx, 1
cmp edx, 4
jl 0x405bf3
push 0x8000
push 0x3f8
mov ecx, 0x4233a8
call fcn.00404660
imul esi, esi, 0x19
push esi
lea ecx, [esp + 0x44]
push 0x41c768
push ecx
call fcn.0040ab25
add esp, 0xc
lea edx, [esp + 0x40]
push edx
push 0x3f8
mov ecx, 0x4233a8
call fcn.00404400
mov ecx, dword [esp + 0x140]
pop ebp
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.0040a66a
add esp, 0x134
ret