[issue6823] time.strftime does unnecessary range check

2009-09-21 Thread Brett Cannon
Brett Cannon br...@python.org added the comment: time.strftime() now normalizes tm_isdst. 2.7: r75011 3.2: r75012 This could probably be backported to 2.6/3.1, but since this is purely a convenience thing and it is a (very) minor change in semantics I am not going to bother. Thanks, Robert,

[issue6823] time.strftime does unnecessary range check

2009-09-08 Thread Richard Shapiro
Richard Shapiro rashapir...@gmail.com added the comment: Here's a patch to normalize the results of the various system calls which return time information. This was against the source for Python 2.5.1. *** timemodule.cTue Sep 8 10:28:31 2009 ---

[issue6823] time.strftime does unnecessary range check

2009-09-08 Thread Brett Cannon
Changes by Brett Cannon br...@python.org: -- keywords: +patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6823 ___ ___ Python-bugs-list mailing

[issue6823] time.strftime does unnecessary range check

2009-09-03 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: Assigning to Brett who added this check in r35368. -- assignee: - brett.cannon nosy: +brett.cannon, georg.brandl ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6823

[issue6823] time.strftime does unnecessary range check

2009-09-03 Thread Brett Cannon
Brett Cannon br...@python.org added the comment: Ugh, damn platforms and having to be different. =) Normalization is the best solution as Python's docs says the expected value for the tm_dst field is -1, 0, or 1 (which is why I added the check). -- keywords: +easy priority: - low

[issue6823] time.strftime does unnecessary range check

2009-09-02 Thread Richard Shapiro
New submission from Richard Shapiro rashapir...@gmail.com: in Modules/timemodule.c, in the routine time_strftime, there is a range check on the tm_isdst field: if (buf.tm_isdst -1 || buf.tm_isdst 1) { PyErr_SetString(PyExc_ValueError, daylight