[mythtv-users] Filename Hell

Simon Hobson linux at thehobsons.co.uk
Mon Nov 19 12:25:57 UTC 2018


Stephen Worthington <stephen_agent at jsw.gen.nz> wrote:

> GMT (Greenwich Mean Time) does not exist and has not existed since the
> UTC time standard was established last century and was legislated in
> most countries to become the only time standard.

Being pedantic, yes it does still exist - it's my current time zone.
For just about all practical purposes they are the same, but AAUI there can occasionally be a second or two difference between GMT and UTC due to leap seconds and stuff. Or am I thinking of the difference between UTC and the new standard being proposed that won't have leap seconds and so the two will slowly diverge by a second or two per year ?
https://www.timeanddate.com/time/zone/uk

> But people often still refer to the UTC+0 time zone as GMT.

Because if you are in a country that uses it, that's the official timezone.

> The reason for using UTC in the file names is to prevent clashes of file names.

And it's how any modern computer system stores (or should store) all dates/times. There have been cases where timezone errors have caused problems : One I recall being a prosecution for downloading illegal material where the timezone difference between the prosecutor's request (which I suspect didn't specify time zone) and the ISPs records caused the wrong information to be returned. IIRC the address had been re-assigned to a different customer and it got as far as court before the case collapsed due to false evidence.

IIRC going back a bit now, when the Mac first started supporting timezones, filesystem times were still stored as local times - and changing timezone caused all the times to be altered. Also, if on a network, then you'd see files on a server in a different timezone with wrong times on them.

So yes, it's important to be consistent in time storage - and using UTC for everything and converting to/from local time as required is normally the best way to do that.

For some amusement : https://infiniteundo.com/post/25326999628/falsehoods-programmers-believe-about-time

And for a bit more amusement : https://www.kalzumeus.com/2010/06/17/falsehoods-programmers-believe-about-names/



More information about the mythtv-users mailing list