diff options
author | Skip Montanaro <skip@pobox.com> | 2002-03-22 18:35:51 +0000 |
---|---|---|
committer | Skip Montanaro <skip@pobox.com> | 2002-03-22 18:35:51 +0000 |
commit | 611e03575c1a106614b27552fdab6684e58c3e2f (patch) | |
tree | 32720f83351f3f74f1e24f3c96deeeece5189389 /Lib/calendar.py | |
parent | fd0446ff010c548051b186349ec3ebaa6892e7b8 (diff) | |
download | cpython-611e03575c1a106614b27552fdab6684e58c3e2f.tar.gz |
better solution for bug #533234 courtesy of Tim.
Michael: use this version as the bugfix candidate...
Diffstat (limited to 'Lib/calendar.py')
-rw-r--r-- | Lib/calendar.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Lib/calendar.py b/Lib/calendar.py index 9ae768af66..cb6354784e 100644 --- a/Lib/calendar.py +++ b/Lib/calendar.py @@ -33,7 +33,8 @@ class _localized_name: if item < 0: item += self.len if not 0 <= item < self.len: raise IndexError, "out of range" - return strftime(self.format, (item,)*8+(0,)).capitalize() + t = (2001, 1, item+1, 12, 0, 0, item, item+1, 0) + return strftime(self.format, t).capitalize() elif isinstance(item, type(slice(0))): return [self[e] for e in range(self.len)].__getslice__(item.start, item.stop) def __len__(self): |