Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: f02d74bb33b91ea8652fb5877c19feb8d6cc3f36
Ticket: 1746193fffffffffffffffffffffffffffffffff
[clock add] month miscalculation in Chicago time
User & Date: andygoth on 2007-07-02 05:17:03
Changes

  1. icomment:
    Logged In: YES 
    user_id=8653
    Originator: YES
    
    The problem appears to be in [clock add].  [clock scan] and [clock format] generate the right results, of course assuming GNU date is right. :^)
    
    [clock add 12960000 -1 month] returns 10368000, which is May 1.  It should return 10281600, or Apr 30.  The two values differ by 86400, one day.
    
    Hmm, come to think of it... [clock add] takes a -timezone argument as well.  Passing in -timezone :UTC to [clock add] makes it return 10281600, the expected result.  I'm unsure why the -timezone argument matters in this case, though.  This may still bear investigation.
    
    
  2. login: "andygoth"
  3. mimetype: "text/plain"
  4. username: "andygoth"