Re: [Sccs-devel] Bugs handling UTC in 5.08
The UNIX Source Code Control System activelty maintained/enhanced
Brought to you by:
schily
From: Bruce L. <bru...@gm...> - 2015-10-13 16:07:07
|
Partial response: On Tue, Oct 13, 2015 at 8:44 AM, Joerg Schilling <Joe...@fo...> wrote: > Bruce Lilly <bru...@gm...> wrote: > >> This started as a bug-fix for prs.c, which wouldn't compile with >> -DGMT_TIME. During testing, I found several related bugs, and added some >> related features which I've been using locally for some time. These may >> help with v6. > > No, SCCSv6 does not need the workaround introduced by Sun between 1990 and 2006. > This is because SCCS now supports much better and unique time stamp handling > that includes GMT-offset. > >> Related bugs fixed: >> >> * Incorrect time (not corrected for zone offset) resulting in warnings >> about retrieval time being older than delta time (noticeable West of the >> Prime Meridian). > > Could you please give a test case for the problem you have in mind? With prs.c patched but w/o the patch to dodelt.c: Script started on Tue Oct 13 11:48:58 2015 # date -u +%%Z%%%Y-%m-%dT%H:%M:%SZ > test.txt # /opt/schily/ccs/bin/admin -itest.txt s.test.txt # rm test.txt # /opt/schily/ccs/bin/get s.test.txt Time stamp later than current clock time (co10) 1.1 1 lines # head -99 test.txt s.test.txt ==> test.txt <== @(#)2015-10-13T15:49:03Z ==> s.test.txt <== h09367 s 00001/00000/00000 d D 1.1 15/10/13 15:49:09 root 1 0 c date and time created 15/10/13 15:49:09 by root e u U f e 0 G r t T I 1 %Z%2015-10-13T15:49:03Z E 1 # Script done on Tue Oct 13 11:49:55 2015 Note the erroneous co10 error message. >> Related features added: >> >> * %N% and %O% keywords added and documented. >> >> These are for current date-time and last applied delta date-time, >> respectively. Format is standard date-time format as documented in: > > What is the main purpose for this modification? The purpose is to provide expansion of date-time in standard format. > Note that upper case keywords as extensions are not a good idea as they are > always enabled by default and thus cause compatibility problems with older SCCS > versions. > > ... >> Examples: >> %N% 2015-10-11T17:55:49.104271752Z >> %O% 2015-10-11T11:45:16Z >> >> * Improved parsing of date and time. >> >> In case XPG decides to allow or require standard format date-time in the >> s-file. > > The format of the s.files is bejond POSIX. But the p-file isn't, and the existing format suffer from all of the problems that you noted (and more): [...] > possible but still make the known problems disappear. The problems have been: > > - 2-digit years is a real problem, fixed by using 4+ digits in V6 > > - local time without GMT-offset causes undeterminable time stamps. > The problem is even present when always operating in the same timezone > as there are DST switches that may the time to appear going backwards. > Fixed by always adding a GMT offset. > > - coarse time resolution, fixed by optional second fraction up to > nanosecond resolution. |