]> www.wagner.pp.ru Git - oss/ctypescrypto.git/commitdiff
Fix fallback timezone definition
authorVictor Wagner <vitus@wagner.pp.ru>
Sat, 20 Dec 2014 12:55:09 +0000 (15:55 +0300)
committerVictor Wagner <vitus@wagner.pp.ru>
Sat, 20 Dec 2014 12:55:09 +0000 (15:55 +0300)
This fallback is used only when pytz is not installed, so it haven't
been tested yet

ctypescrypto/x509.py

index af61942adc5f685d1db83c299b2ac033f51bd37d..44919f1ff9a26be49f66b80570872018c319f84c 100644 (file)
@@ -18,9 +18,9 @@ from datetime import datetime
 try:
        from pytz import utc
 except ImportError:
-       from datetime import timedelta
+       from datetime import timedelta,tzinfo
        ZERO=timedelta(0)
-       class UTC(datetime.tzinfo):
+       class UTC(tzinfo):
                """tzinfo object for UTC. 
                        If no pytz is available, we would use it.
                """