[Buildbot-commits] buildbot/buildbot/slave commands.py,1.31,1.32

Mike Taylor code-bear at users.sourceforge.net
Fri May 13 23:15:36 UTC 2005


Update of /cvsroot/buildbot/buildbot/buildbot/slave
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31538/buildbot/slave

Modified Files:
	commands.py 
Log Message:
buildbot/slave/commands.py (rmdirRecursive): added a check
to ensure the path passed into rmdirRecursive actually exists.
On win32 a non-existant path would generate an exception.


Index: commands.py
===================================================================
RCS file: /cvsroot/buildbot/buildbot/buildbot/slave/commands.py,v
retrieving revision 1.31
retrieving revision 1.32
diff -u -d -r1.31 -r1.32
--- commands.py	13 May 2005 20:28:11 -0000	1.31
+++ commands.py	13 May 2005 23:15:34 -0000	1.32
@@ -32,6 +32,9 @@
 def rmdirRecursive(dir):
     """This is a replacement for shutil.rmtree that works better under
     windows. Thanks to Bear at the OSAF for the code."""
+    if not os.path.exists(dir):
+        return
+
     if os.path.islink(dir):
         os.remove(dir)
         return





More information about the Commits mailing list