Gentoo Archives: gentoo-commits

From: "Zac Medico (zmedico)" <zmedico@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] portage r14728 - main/trunk/bin
Date: Sun, 25 Oct 2009 22:41:29
Message-Id: E1N2BmC-00032g-24@stork.gentoo.org
1 Author: zmedico
2 Date: 2009-10-25 22:41:27 +0000 (Sun, 25 Oct 2009)
3 New Revision: 14728
4
5 Modified:
6 main/trunk/bin/repoman
7 Log:
8 Use calendar.timegm instead of time.mktime, for correct timezone handling.
9
10
11 Modified: main/trunk/bin/repoman
12 ===================================================================
13 --- main/trunk/bin/repoman 2009-10-25 20:27:02 UTC (rev 14727)
14 +++ main/trunk/bin/repoman 2009-10-25 22:41:27 UTC (rev 14728)
15 @@ -9,6 +9,7 @@
16
17 from __future__ import print_function
18
19 +import calendar
20 import codecs
21 try:
22 from subprocess import getstatusoutput as subprocess_getstatusoutput
23 @@ -824,7 +825,7 @@
24 elif last_modified is not None:
25 last_modified = parsedate(last_modified)
26 if last_modified is not None:
27 - last_modified = time.mktime(last_modified)
28 + last_modified = calendar.timegm(last_modified)
29
30 metadata_dtd_tmp = "%s.%s" % (metadata_dtd, os.getpid())
31 try: