Index: base/file_util_win.cc |
=================================================================== |
--- base/file_util_win.cc (revision 34723) |
+++ base/file_util_win.cc (working copy) |
@@ -528,7 +528,11 @@ |
// Attempt to create the parent recursively. This will immediately return |
// true if it already exists, otherwise will create all required parent |
// directories starting with the highest-level missing parent. |
- if (!CreateDirectory(full_path.DirName())) { |
+ FilePath parent_path(full_path.DirName()); |
+ if (parent_path.value() == full_path.value()) { |
+ return false; |
+ } |
+ if (!CreateDirectory(parent_path)) { |
DLOG(WARNING) << "Failed to create one of the parent directories."; |
return false; |
} |