Consolidate several near-identical uses of mktime() into a single
authorTom Lane <tgl@sss.pgh.pa.us>
Thu, 3 May 2001 22:53:07 +0000 (22:53 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Thu, 3 May 2001 22:53:07 +0000 (22:53 +0000)
commitee5977a3f1a888cef3efe5adaa9e5140f23b82d5
treef71f4bbf6b5f6b2e2f7141a5788becf260d5f673
parentb27838fd33778baa5917642130e7cc86a08e68be
Consolidate several near-identical uses of mktime() into a single
routine DetermineLocalTimeZone().  In that routine, be more wary of
broken mktime() implementations than the original code was: don't allow
mktime to change the already-set y/m/d/h/m/s information, and don't
use tm_gmtoff if mktime failed.  Possibly this will resolve some of
the complaints we've been hearing from users of Middle Eastern timezones
on RedHat.
src/backend/utils/adt/datetime.c
src/backend/utils/adt/formatting.c
src/backend/utils/adt/timestamp.c
src/include/utils/datetime.h