Rev 5284: Really fix and better explain why we need both the module and the symbol. in file:///home/vila/src/bzr/experimental/leaking-tests/

Vincent Ladeuil v.ladeuil+lp at free.fr
Tue Jun 29 18:46:25 BST 2010


At file:///home/vila/src/bzr/experimental/leaking-tests/

------------------------------------------------------------
revno: 5284
revision-id: v.ladeuil+lp at free.fr-20100629174625-6rs2pen7u7fv55b6
parent: v.ladeuil+lp at free.fr-20100629162324-ls01yzl823613kg4
committer: Vincent Ladeuil <v.ladeuil+lp at free.fr>
branch nick: cleanup
timestamp: Tue 2010-06-29 19:46:25 +0200
message:
  Really fix and better explain why we need both the module and the symbol.
-------------- next part --------------
=== modified file 'bzrlib/osutils.py'
--- a/bzrlib/osutils.py	2010-06-29 16:23:24 +0000
+++ b/bzrlib/osutils.py	2010-06-29 17:46:25 +0000
@@ -28,10 +28,16 @@
 import getpass
 import ntpath
 import posixpath
+# We need to import both shutil and rmtree as we export the later on posix
+# and need the former on windows
+import shutil
 from shutil import rmtree
 import socket
 import subprocess
-import tempfile import mkdtemp
+# We need to import both tempfile and mkdtemp as we export the later on posix
+# and need the former on windows
+import tempfile
+from tempfile import mkdtemp
 import unicodedata
 
 from bzrlib import (
@@ -346,7 +352,7 @@
 
 
 def _win32_mkdtemp(*args, **kwargs):
-    return _win32_fixdrive(tempfile.mkdtemp(*args, **kwargs).replace('\\', '/'))
+    return _win32_fixdrive(mkdtemp(*args, **kwargs).replace('\\', '/'))
 
 
 def _win32_rename(old, new):



More information about the bazaar-commits mailing list