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

English support forum

Moderators: sheep, Hacker, Stefan2, white

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 » 2019-06-05, 14:29 UTC

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: 551
Joined: 2011-03-11, 10:11 UTC

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

Post by *Usher » 2019-06-06, 01:10 UTC

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
---------------------------
Regards from Poland
Andrzej P. Wozniak

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 » 2019-06-06, 08:47 UTC

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