'Total space occupied' calculation: is not being rounded up as expected

English support forum

Moderators: white, Hacker, petermad, Stefan2

Post Reply
OldNorton
Junior Member
Junior Member
Posts: 7
Joined: 2019-06-05, 14:09 UTC

'Total space occupied' calculation: is not being rounded up as expected

Post by *OldNorton »

Doing a ^L for a selected file I get the following information:

Image: http://i64.tinypic.com/2qcjlh3.jpg

TC says:
2,093,767 bytes (= 2,044k 1M)

As I understand it:
2,093,767 b / 1,024 = 2,044 k
2,044 k / 1,024 = 1.997 M

But should it not be rounded up to 2M? What is my mistake there?
User avatar
Usher
Power Member
Power Member
Posts: 1675
Joined: 2011-03-11, 10:11 UTC

Re: 'Total space occupied' calculation: is not being rounded up as expected

Post by *Usher »

Actually both values are rounded down. In my case 32-bit TC 9.22a displays 2045 k and 2 M:

---------------------------
Total Commander
---------------------------
Total space occupied:
2 093 767 bytes in 1 file(s)

(= 2 045k, 2M)

Actual space used (considering cluster size)
on source drive: 2 097 152 Bytes
Required on target drive: 2 097 152 Bytes

c:\ : 3 336 828 k of 262 138 272 k free
---------------------------
OK
---------------------------
Andrzej P. Wozniak
Polish subforum moderator
OldNorton
Junior Member
Junior Member
Posts: 7
Joined: 2019-06-05, 14:09 UTC

Re: 'Total space occupied' calculation: is not being rounded up as expected

Post by *OldNorton »

You are right, Usher! I did not catch the 2,044 (->2,045 k) at first. So is it a bug for the latest 64-bit version?
Post Reply