[Zope-Checkins] CVS: Packages/DateTime - DateTime.py:1.85.12.12
Lennart Regebro
regebro at nuxeo.com
Mon Nov 8 13:51:14 EST 2004
Update of /cvs-repository/Packages/DateTime
In directory cvs.zope.org:/tmp/cvs-serv11906/lib/python/DateTime
Modified Files:
Tag: Zope-2_7-branch
DateTime.py
Log Message:
Collector #1127 fixed: strftime returned the incorrect time if the timezone was not the same as the local timezone.
=== Packages/DateTime/DateTime.py 1.85.12.11 => 1.85.12.12 ===
--- Packages/DateTime/DateTime.py:1.85.12.11 Mon Aug 2 05:49:18 2004
+++ Packages/DateTime/DateTime.py Mon Nov 8 13:50:43 2004
@@ -1488,12 +1488,8 @@
return millis
def strftime(self, format):
- # Format the date/time using the *current timezone representation*.
- diff = _tzoffset(self._tz, self._t)
- format = re.sub('(^\|[^%])%z',
- '\\1%+05d' % (diff / 36),
- format)
- return strftime(format, safegmtime(self.timeTime() + diff))
+ # Format the date/time using the *local timezone representation*.
+ return strftime(format, safelocaltime(self.timeTime()))
# General formats from previous DateTime
def Date(self):
More information about the Zope-Checkins
mailing list