mirror of
https://github.com/python/cpython.git
synced 2025-10-12 18:02:39 +00:00
[Bug #945063] Get file extension correct. (2.3 bugfix candidate)
This commit is contained in:
parent
67a521ef69
commit
30633c9a64
1 changed files with 1 additions and 1 deletions
|
@ -274,7 +274,7 @@ class Hook:
|
||||||
|
|
||||||
if self.logdir is not None:
|
if self.logdir is not None:
|
||||||
import os, tempfile
|
import os, tempfile
|
||||||
suffix = ['.html', '.txt'][self.format=="html"]
|
suffix = ['.txt', '.html'][self.format=="html"]
|
||||||
(fd, path) = tempfile.mkstemp(suffix=suffix, dir=self.logdir)
|
(fd, path) = tempfile.mkstemp(suffix=suffix, dir=self.logdir)
|
||||||
try:
|
try:
|
||||||
file = os.fdopen(fd, 'w')
|
file = os.fdopen(fd, 'w')
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue