Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 53cc6f487ae961a35930db4aef47b7a44849bf78
Ticket: aa082a279c5d3a39d400fd9e8137ba0544422091
clock format "time zone not found" with valid zoneinfo file
User & Date: karl on 2016-06-03 17:13:58
Changes

  1. icomment:
    I think the main problem is it should pass $date and not $y to IsGregorianLeapYear.  This diff seems to fix the problem, but it sets Gregorian to 1 and thus may malfunction for dates before September of 1752:
    
    --- /usr/local/lib/tcl8.6/clock.tcl	2016-03-01 13:51:46.077512000 +0000
    +++ clock.tcl	2016-06-03 14:51:42.050504100 +0000
    @@ -3881,14 +3881,14 @@
     
         # Determine the start or end day of DST
     
    -    set date [dict create era CE year $y]
    +    set date [dict create era CE year $y gregorian 1]
         set doy [dict get $z ${bound}DayOfYear]
         if { $doy ne {} } {
     
     	# Time was specified as a day of the year
     
     	if { [dict get $z ${bound}J] ne {}
    -	     && [IsGregorianLeapYear $y]
    +	     && [IsGregorianLeapYear $date]
     	     && ( $doy > $FEB_28 ) } {
     	    incr doy
     	}
    
  2. login: "karl"
  3. mimetype: "text/plain"