Additional fix for issue #1249 (Mkdir fails if dir exists) on Windows.
authorgaryo <garyo@fdb21ef1-2011-0410-befe-b5e4ea1792b1>
Sat, 31 Jan 2009 23:02:08 +0000 (23:02 +0000)
committergaryo <garyo@fdb21ef1-2011-0410-befe-b5e4ea1792b1>
Sat, 31 Jan 2009 23:02:08 +0000 (23:02 +0000)
git-svn-id: http://scons.tigris.org/svn/scons/trunk@3941 fdb21ef1-2011-0410-befe-b5e4ea1792b1

src/engine/SCons/Defaults.py

index 4a1bcde8bf7321066ea6059735db6919aec5ed58..2b4b967e218af0870a115376e8f1c02c159f988a 100644 (file)
@@ -225,7 +225,8 @@ def mkdir_func(dest):
             os.makedirs(str(entry))
         except os.error, e:
             p = str(entry)
-            if e[0] == errno.EEXIST and os.path.isdir(str(entry)):
+            if (e[0] == errno.EEXIST or (sys.platform=='win32' and e[0]==183)) \
+                    and os.path.isdir(str(entry)):
                 pass            # not an error if already exists
             else:
                 raise