| Index: base/scoped_temp_dir.cc
|
| ===================================================================
|
| --- base/scoped_temp_dir.cc (revision 67430)
|
| +++ base/scoped_temp_dir.cc (working copy)
|
| @@ -57,10 +57,19 @@
|
| return true;
|
| }
|
|
|
| -void ScopedTempDir::Delete() {
|
| - if (!path_.empty() && !file_util::Delete(path_, true))
|
| +bool ScopedTempDir::Delete() {
|
| + if (path_.empty())
|
| + return false;
|
| +
|
| + bool ret = file_util::Delete(path_, true);
|
| + if (ret) {
|
| + // We only clear the path if deleted the directory.
|
| + path_.clear();
|
| + } else {
|
| LOG(ERROR) << "ScopedTempDir unable to delete " << path_.value();
|
| - path_.clear();
|
| + }
|
| +
|
| + return ret;
|
| }
|
|
|
| FilePath ScopedTempDir::Take() {
|
|
|