Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit e6e77e5

Browse files
author
Michael W. Hudson
committed
Fix
[ 777659 ] Uninitialized variable used in Tools/faqwiz/faqwiz.py with help from jlgijsbers on #python-dev IRC.
1 parent 618fbf5 commit e6e77e5

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

Tools/faqwiz/faqwiz.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -808,7 +808,7 @@ def commit(self, entry):
808808

809809
import tempfile
810810
tf = tempfile.NamedTemporaryFile()
811-
emit(LOGHEADER, self.ui, os.environ, date=date, _file=tfn)
811+
emit(LOGHEADER, self.ui, os.environ, date=date, _file=tf)
812812
tf.flush()
813813
tf.seek(0)
814814

@@ -830,7 +830,7 @@ def commit(self, entry):
830830
print '<PRE>%s</PRE>' % escape(output)
831831

832832
try:
833-
os.unlink(tfn)
833+
os.unlink(tf.name)
834834
except os.error:
835835
pass
836836

0 commit comments

Comments
 (0)