[Python-checkins] cpython (3.2): Issue #10653: On Windows, use strftime() instead of wcsftime() because

victor.stinner python-checkins at python.org
Fri Oct 14 02:38:21 CEST 2011


http://hg.python.org/cpython/rev/e3d9c5e690fc
changeset:   72919:e3d9c5e690fc
branch:      3.2
parent:      72907:d18c80a8c119
user:        Victor Stinner <victor.stinner at haypocalc.com>
date:        Fri Oct 14 02:36:13 2011 +0200
summary:
  Issue #10653: On Windows, use strftime() instead of wcsftime() because
wcsftime() doesn't format time zone correctly.

files:
  Misc/NEWS            |  3 +++
  Modules/timemodule.c |  5 +++++
  2 files changed, 8 insertions(+), 0 deletions(-)


diff --git a/Misc/NEWS b/Misc/NEWS
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -43,6 +43,9 @@
 Library
 -------
 
+- Issue #10653: On Windows, use strftime() instead of wcsftime() because
+  wcsftime() doesn't format time zone correctly.
+
 - Issue #11171: Fix distutils.sysconfig.get_makefile_filename when Python was
   configured with different prefix and exec-prefix.
 
diff --git a/Modules/timemodule.c b/Modules/timemodule.c
--- a/Modules/timemodule.c
+++ b/Modules/timemodule.c
@@ -431,6 +431,11 @@
     return 1;
 }
 
+#ifdef MS_WINDOWS
+   /* wcsftime() doesn't format correctly time zones, see issue #10653 */
+#  undef HAVE_WCSFTIME
+#endif
+
 #ifdef HAVE_STRFTIME
 #ifdef HAVE_WCSFTIME
 #define time_char wchar_t

-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list