[8.0b1 - x64 + x86] Time issues on certain files and dirs.

The behaviour described in the bug report is either by design, or would be far too complex/time-consuming to be changed

Moderators: Hacker, petermad, Stefan2, white

Post Reply
User avatar
Kishiro
Junior Member
Junior Member
Posts: 23
Joined: 2005-03-19, 00:01 UTC
Location: Norway

[8.0b1 - x64 + x86] Time issues on certain files and dirs.

Post by *Kishiro »

When comparing the 8.0b1 Build (both x64 and 32-bit) to the previous version, 7.56a, I discovered that certain files and directories were off in timestamps of approx. an hour. Not all files, just some. weird... I used the same ini file on all the builds, and I ALT+Tabbed between them.

Image: http://home.lyse.net/kishiro/images/tc/tc_time_bug.png
User avatar
Kishiro
Junior Member
Junior Member
Posts: 23
Joined: 2005-03-19, 00:01 UTC
Location: Norway

Post by *Kishiro »

Update; After comparing in various programs and explorer itself, I've concluded that the bug must be in the old 7.56a version not the new 8.01 version.

Moderator; you can delete this thread if you like. or movie it to the "TC7.56(a) bug reports (English)" sub-forum. :wink:
User avatar
Hacker
Moderator
Moderator
Posts: 13142
Joined: 2003-02-06, 14:56 UTC
Location: Bratislava, Slovakia

Post by *Hacker »

history.txt wrote:24.07.11 Added: wincmd.ini [Configuration] NewTimeZoneMethod=1/0 sets new Windows 7 time zone method (32/64)
24.07.11 Added: Windows 7: Use new timestamp display method as in Explorer (32/64)
Perhaps?

Roman
Mal angenommen, du drückst Strg+F, wählst die FTP-Verbindung (mit gespeichertem Passwort), klickst aber nicht auf Verbinden, sondern fällst tot um.
User avatar
karlchen
Power Member
Power Member
Posts: 4605
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

Hi, Roman.

Great. :wink:
Yet, I am afraid I still wonder what this new method is in detail. :?
Have you got any idea? Else we may have to wait for Christian to explain.

Cheers,
Karl
Sob
Power Member
Power Member
Posts: 945
Joined: 2005-01-19, 17:33 UTC

Post by *Sob »

It's how DST is handled. To see what's going on, I used simple script to create 365 files with dates from 2011-01-01 to 2011-12-31 (one file per each day) and time 12:00 (noon) UTC.

My default timezone is UTC+1 and UTC+2 when DST is active.

With current system date (DST active):
- TC 8: from 2011-03-27 to 2011-10-29 the time is 14:00, the rest 13:00
- TC 7: time for all files is 14:00

With december 2011 as system date (no DST):
- TC 8: from 2011-03-27 to 2011-10-29 the time is 14:00, the rest 13:00 (same as before)
- TC 7: time for all files is 13:00

Explanation:
TC 8 shows time related to the date of each file and timezone which was valid at that date = times stay always the same.
TC 7 simply takes UTC and adjusts it according to timezone valid now = times change depending on whenever DST is currently active or not.

My vote goes to TC 8.
User avatar
karlchen
Power Member
Power Member
Posts: 4605
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

Hello, Sob.

Thanks for taking the time of investing this and explaining it so nicely.
Yep, agreed, the new TC 8 approach where the displayed timestamps remain unmodified in summer and in wintertime seems more logical to me as well. :)

So the reported behaviour is a feature rather than a bug.

Cheers,
Karl
User avatar
petermad
Power Member
Power Member
Posts: 16032
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Post by *petermad »

It works OK for NTFS partitions, but unfortunately it also works on FAT and archives, which it should not.

The time is always the same on FAT partitions and in archives and should not be adjusted according to timezone and DST, but with NewTimeZoneMethod=1 they unfortunately are. This results in different time for for example unpacked files depending on whether DST is active or not, and whether they are unpacked to FAT or NTFS.
License #524 (1994)
Danish Total Commander Translator
TC 11.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1391a
TC 3.60b4 on Android 6, 13, 14
TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
Sob
Power Member
Power Member
Posts: 945
Joined: 2005-01-19, 17:33 UTC

Post by *Sob »

It depends how time is stored. NTFS with times in UTC is fine, because it always refers to exact moment. For FAT using local time, there's really no hope at all, because it can mean anything. So the least wrong approach is to show it as is. If TC adjusts it, I'd say it's bug.

The same rules apply for archives. If archive stores UTC, then there's no problem, because it's exact time. If it stores local time, then again better not touch it. If I created modern archiver, I'd definitely use UTC. But what popular formats actually use, I have no idea.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50532
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Yes, it's a new feature to show the same times as in Explorer (and Alt+Enter properties).
It depends how time is stored. NTFS with times in UTC is fine, because it always refers to exact moment. For FAT using local time, there's really no hope at all, because it can mean anything. So the least wrong approach is to show it as is. If TC adjusts it, I'd say it's bug.
Unfortunately the Explorer does the same, so it's better to do it also in TC...
Author of Total Commander
https://www.ghisler.com
User avatar
petermad
Power Member
Power Member
Posts: 16032
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Post by *petermad »

How about making it optional:

NewTimeZoneMethod=2

= don't change time when UTC-time is not nown (FAT, most archives)
License #524 (1994)
Danish Total Commander Translator
TC 11.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1391a
TC 3.60b4 on Android 6, 13, 14
TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50532
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

That would indeed be nice, but I fear that checking the file system for every single file would be terribly slow. This would be necessary because NTFS also allows hard links to files on other drives, even FAT.
Author of Total Commander
https://www.ghisler.com
User avatar
Flint
Power Member
Power Member
Posts: 3506
Joined: 2003-10-27, 09:25 UTC
Location: Belgrade, Serbia
Contact:

Post by *Flint »

ghisler(Author) wrote:This would be necessary because NTFS also allows hard links to files on other drives, even FAT.
Hard links on files from different partition are impossible, because hard links are just a counter in NTFS internal structure. The file must be located inside the same file system for it to work.

NTFS can store symbolic links to files from different partitions (starting from Vista), but AFAIK the link has its own timestamp, so it does not have to be re-checked separately. And NTFS can store symlinks to directories on different partitions, but when you enter such a directory by a symlink, all the files in it will be on the same partition, so it is not necessary to check every file.
Flint's Homepage: Full TC Russification Package, VirtualDisk, NTFS Links, NoClose Replacer, and other stuff!
 
Using TC 11.03 / Win10 x64
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50532
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

You are right, it was about directories, not files. It's still not se easy, e.g. in case of branch view or search - feed in listbox.
Author of Total Commander
https://www.ghisler.com
User avatar
petermad
Power Member
Power Member
Posts: 16032
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Post by *petermad »

2ghisler(Author)
Unfortunately the Explorer does the same
That depends on the OS. Here Explorer under Win XP shows the untouched time of files in archives, but changes the time for the same files under Win 7.

Maybe at least keep the "old way" for archives...
License #524 (1994)
Danish Total Commander Translator
TC 11.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1391a
TC 3.60b4 on Android 6, 13, 14
TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
User avatar
Flint
Power Member
Power Member
Posts: 3506
Joined: 2003-10-27, 09:25 UTC
Location: Belgrade, Serbia
Contact:

Post by *Flint »

ghisler(Author) wrote:It's still not se easy, e.g. in case of branch view or search - feed in listbox.
Ah, right. I didn't think about them.
Flint's Homepage: Full TC Russification Package, VirtualDisk, NTFS Links, NoClose Replacer, and other stuff!
 
Using TC 11.03 / Win10 x64
Post Reply