]> git.pld-linux.org Git - projects/pld-builder.new.git/commitdiff
Use correct timezone offset.
authorArkadiusz Miśkiewicz <arekm@maven.pl>
Tue, 28 Jun 2011 13:53:12 +0000 (13:53 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    PLD_Builder/request.py -> 1.91

PLD_Builder/request.py

index 992c8751f163eaf4c01ac405f7d31c9418836487..0c07d8947ceccd7e7b438d258278ed116972c886 100644 (file)
@@ -43,7 +43,8 @@ def tzdate(t):
     date = time.strftime("%a %b %d %Y %H:%M:%S", time.localtime(t))
     # NOTE: the altzone is showing CURRENT timezone, not what the "t" reflects
     # NOTE: when DST is off timezone gets it right, altzone not
-    tz = '{:=+05d}'.format(-time.timezone / 3600 * 100)
+    tzoffset = time.altzone if time.daylight else time.timezone
+    tz = '{:=+05d}'.format(-tzoffset / 3600 * 100)
     return date + ' ' + tz
 
 def is_blank(e):
This page took 0.069599 seconds and 4 git commands to generate.