OLD | NEW |
---|---|
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/chromeos/drive/drive_integration_service.h" | 5 #include "chrome/browser/chromeos/drive/drive_integration_service.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/file_util.h" | 8 #include "base/file_util.h" |
9 #include "base/prefs/pref_change_registrar.h" | 9 #include "base/prefs/pref_change_registrar.h" |
10 #include "base/prefs/pref_service.h" | 10 #include "base/prefs/pref_service.h" |
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
144 dest_directory = downloads_directory.Append( | 144 dest_directory = downloads_directory.Append( |
145 base::FilePath::FromUTF8Unsafe(dest_directory_name)) | 145 base::FilePath::FromUTF8Unsafe(dest_directory_name)) |
146 .InsertBeforeExtensionASCII(base::StringPrintf(" (%d)", uniquifier)); | 146 .InsertBeforeExtensionASCII(base::StringPrintf(" (%d)", uniquifier)); |
147 } | 147 } |
148 | 148 |
149 internal::ResourceMetadataStorage::RecoveredCacheInfoMap | 149 internal::ResourceMetadataStorage::RecoveredCacheInfoMap |
150 recovered_cache_info; | 150 recovered_cache_info; |
151 metadata_storage->RecoverCacheInfoFromTrashedResourceMap( | 151 metadata_storage->RecoverCacheInfoFromTrashedResourceMap( |
152 &recovered_cache_info); | 152 &recovered_cache_info); |
153 | 153 |
154 LOG(WARNING) << "DB could not be opened for some reasons. " | 154 VLOG(1) << "DB could not be opened for some reasons. " |
hashimoto
2014/02/03 04:28:18
Could you change this to LOG_IF(WARNING, !recovere
danakj
2014/02/03 16:57:28
Yup that works.
| |
155 << "Recovering cache files to " << dest_directory.value(); | 155 << "Recovering cache files to " << dest_directory.value(); |
156 if (!cache->RecoverFilesFromCacheDirectory(dest_directory, | 156 if (!cache->RecoverFilesFromCacheDirectory(dest_directory, |
157 recovered_cache_info)) { | 157 recovered_cache_info)) { |
158 LOG(WARNING) << "Failed to recover cache files."; | 158 LOG(WARNING) << "Failed to recover cache files."; |
159 return FILE_ERROR_FAILED; | 159 return FILE_ERROR_FAILED; |
160 } | 160 } |
161 } | 161 } |
162 | 162 |
163 FileError error = resource_metadata->Initialize(); | 163 FileError error = resource_metadata->Initialize(); |
164 LOG_IF(WARNING, error != FILE_ERROR_OK) | 164 LOG_IF(WARNING, error != FILE_ERROR_OK) |
165 << "Failed to initialize resource metadata. " << FileErrorToString(error); | 165 << "Failed to initialize resource metadata. " << FileErrorToString(error); |
(...skipping 452 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
618 service = new DriveIntegrationService(profile, preference_watcher, | 618 service = new DriveIntegrationService(profile, preference_watcher, |
619 NULL, base::FilePath(), NULL); | 619 NULL, base::FilePath(), NULL); |
620 } else { | 620 } else { |
621 service = factory_for_test_->Run(profile); | 621 service = factory_for_test_->Run(profile); |
622 } | 622 } |
623 | 623 |
624 return service; | 624 return service; |
625 } | 625 } |
626 | 626 |
627 } // namespace drive | 627 } // namespace drive |
OLD | NEW |