Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 1 Dec 2002 17:05:09 -0800 (PST)
From:      Peter Wemm <peter@FreeBSD.org>
To:        cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject:   cvs commit: src/lib/libc/stdtime localtime.c
Message-ID:  <200212020105.gB21596L092766@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
peter       2002/12/01 17:05:09 PST

  Modified files:
    lib/libc/stdtime     localtime.c 
  Log:
  Replace rev 1.33 with a real fix.  The problem was integer overflows
  when trying to store the year in a signed int.  The maximum time_t on ia64
  is around 292 billion years in the future, but 'int' and struct tm.tm_year
  can only represent then ext 2.1 billion years or so.
  
  This solves the problem of mktime/localtime looping on ia64.  Unfortunately,
  the standards say that tm_year is an 'int', so we are still stuck with a
  y2147483647 bug.  bash2's configure script looks for bugs in mktime() and
  fails on ia64 because of this.  However, mktime() on FreeBSD fails the test
  normally anyway so this is no big loss.
  
  This change does not affect any other platforms besides ia64.
  
  Approved by:    re
  
  Revision  Changes    Path
  1.34      +2 -8      src/lib/libc/stdtime/localtime.c

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200212020105.gB21596L092766>