Wrong time (1 sec diff) displayed in TC 6.53

English support forum

Moderators: white, Hacker, petermad, Stefan2

Post Reply
ecto
Junior Member
Junior Member
Posts: 6
Joined: 2005-12-08, 23:43 UTC
Location: Uppsala, Sweden

Wrong time (1 sec diff) displayed in TC 6.53

Post by *ecto »

Image: http://danny.swalas.org/wrong_time_in_totalcmd.gif

In the above image, Total Commander (6.53, WinXp) displays the date as 16:26:10, but the real date is 16:26:11 (I did a touch to change the time so I know that 11 is the correct number for the seconds).

Why? Is this some kind of rounding error, i.e. invisible milliseconds that are interpreted differently by the properties dialog and TC (one rounding up, one down)?

Sorry if this has been asked before, I did some searching but found no answer.
User avatar
Clo
Moderator
Moderator
Posts: 5731
Joined: 2003-12-02, 19:01 UTC
Location: Bordeaux, France
Contact:

Two by two---

Post by *Clo »

2ecto

:) Hello !

¤ Except I mistake, I think that TC uses(used?) the DOS system for the time which works by 2-second steps…
- Hence, an odd amount of seconds (11) couln't be displayed in the case, just even values “10” or “12”…

:mrgreen: Kind regards,
Claude
Clo
#31505 Traducteur Français de TC French translator Aide en Français Tutoriels Français English Tutorials
ecto
Junior Member
Junior Member
Posts: 6
Joined: 2005-12-08, 23:43 UTC
Location: Uppsala, Sweden

Post by *ecto »

Oh, now that I look a little more closely it seems you are right - I can't see a single file with odd-numbered seconds :)

Seriously though.. this seems a bit tacky. Such a great program as TC, not being able to display odd-numbered seconds? Or is the problem derived from some old file system limitation? Shouldn't be too hard to make a workaround if that's the case, right?

Seems like a silly problem, but it bothers me as I regularly compare (by quick eye-balling) lots of files by their exact date/time :)
User avatar
karlchen
Power Member
Power Member
Posts: 4603
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

Clo is right.

TC sticks to some outdated routine to determine and display filetimes in order to be compatible with old Windows versions that had the 2-seconds-restriction.

TC could do better on NT-based systems, yet Christian Ghisler decided not to implement two different routines for NT-based systems and "prehistoric" systems. :(

I know this has been discussed in this forum before. I am just too lazy now to use the Search button and look up the old thread.

Karl
MX Linux 21.3 64-bit xfce, Total Commander 10.52 64-bit
The people of Alderaan keep on bravely fighting back the clone warriors sent out by the unscrupulous Sith Lord Palpatine.
The Prophet's Song
User avatar
majkinetor
Senior Member
Senior Member
Posts: 369
Joined: 2005-11-20, 10:36 UTC
Location: Belgrade, Serbia
Contact:

Post by *majkinetor »

Add [BUG] prefix in your topic name.

Because this is a bug. I don't care about systems used.
User avatar
SanskritFritz
Power Member
Power Member
Posts: 3693
Joined: 2003-07-24, 09:25 UTC
Location: Budapest, Hungary

Post by *SanskritFritz »

I switched to Linux, bye and thanks for all the fish!
ecto
Junior Member
Junior Member
Posts: 6
Joined: 2005-12-08, 23:43 UTC
Location: Uppsala, Sweden

Post by *ecto »

Thanks everybody for the info.

From the ShellDetails thread:
ghisler(Author) wrote: TC uses the date/time format used by the FAT(32) file system, which is accurate to 2 seconds only. Apparently the seconds are rounded up in one case, and down in the other...
So, this "error" is by design (ie. ghisler decided to do it this way, like karlchen pointed out). My obvious question is; why? If it can be done correctly, why not do it? Too hard, other stuff much more prioritized in the todo-list, or..?

I searched but couldn't find any more info - like exactly why ghisler decided to do it this way and if it's planned to change in the future. If anyone could point me to information about all this, I'd be greatful! :)
aguirRe
Junior Member
Junior Member
Posts: 88
Joined: 2003-02-06, 17:33 UTC
Contact:

Post by *aguirRe »

AFAIK, the limitation is in the file system, not TC itself; it only reads the timestamp via the OS. See here: http://www.jpsoft.com/help/index.htm?timestamps.htm
ecto
Junior Member
Junior Member
Posts: 6
Joined: 2005-12-08, 23:43 UTC
Location: Uppsala, Sweden

Post by *ecto »

Yes, it's a limitation of FAT, but not of NTFS.

So why don't use the added resolution of NTFS when applicable? I haven't used FAT for several years, and I guess most users haven't.

Comments, ghisler?

(Thanks for the link btw aquirRe!)
User avatar
petermad
Power Member
Power Member
Posts: 14809
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Post by *petermad »

2ecto
I guess most users haven't.
Well - floppy disks, CD-ROM's and memorycards usually use FAT - and I personally use both FAT and NTFS on my harddisks - but of course I am not most users ;-)
License #524 (1994)
Danish Total Commander Translator
TC 11.03 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1371a
TC 3.50 on Android 6 & 13
Try: TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
ecto
Junior Member
Junior Member
Posts: 6
Joined: 2005-12-08, 23:43 UTC
Location: Uppsala, Sweden

Post by *ecto »

Ok, you got me about the CD-ROMs (and floppies) :), but I still don't understand why TC doesn't use NTFS timestamp when available..
User avatar
petermad
Power Member
Power Member
Posts: 14809
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Post by *petermad »

2ecto
I agree - NTFS timestamp should be used when available.
License #524 (1994)
Danish Total Commander Translator
TC 11.03 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1371a
TC 3.50 on Android 6 & 13
Try: TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
User avatar
Sheepdog
Power Member
Power Member
Posts: 5150
Joined: 2003-12-18, 21:44 UTC
Location: Berlin, Germany
Contact:

Post by *Sheepdog »

petermad wrote:CD-ROM's... usually use FAT -
Sorry, but CD-Rom does not use FAT at all but ISO 9696 or newer the UDF-filesystem. That's the main reason you could not access a CD-Rom on DOS or Win95 Machines withouit a proper driver.

On the other hand I agree that FAT is still in use at many machines e.g all machines that still run Win95/98 mandatory use the FAT format. And for external harddiscs it is mostly a good idea, too, to use FAT because FAT is supported by many different Operating systems - so you can access Data on FAT partitions from MAC-OS, Windows or Unix.

sheepdog
"A common mistake that people make when trying to design something
completely foolproof is to underestimate the ingenuity of complete fools."
Douglas Adams
User avatar
petermad
Power Member
Power Member
Posts: 14809
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Post by *petermad »

2Sheepdog
CD-Rom does not use FAT
Sorry you are right of course - I even tested a little - it seems that ISO supports uneven seconds in the timestamp, as do UDF.
License #524 (1994)
Danish Total Commander Translator
TC 11.03 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1371a
TC 3.50 on Android 6 & 13
Try: TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
Post Reply