Commit 50d0cc96 authored by Bo Liu's avatar Bo Liu Committed by Commit Bot

weblayer: Add error message for delete profile data

Add an error if marker file creation failed.

Bug: 1065585
Change-Id: Iaa86c52b63111097b675f93bdad95ce706cde3d0
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2148840Reviewed-by: default avatarScott Violet <sky@chromium.org>
Commit-Queue: Bo <boliu@chromium.org>
Cr-Commit-Position: refs/heads/master@{#758868}
parent e3b65800
...@@ -107,6 +107,10 @@ void MarkProfileAsDeleted(const ProfileInfo& info) { ...@@ -107,6 +107,10 @@ void MarkProfileAsDeleted(const ProfileInfo& info) {
CHECK(data_root_path.AppendRelativePath(info.data_path, &marker_path)); CHECK(data_root_path.AppendRelativePath(info.data_path, &marker_path));
base::File file(marker_path, base::File file(marker_path,
base::File::FLAG_CREATE | base::File::FLAG_WRITE); base::File::FLAG_CREATE | base::File::FLAG_WRITE);
if (!base::PathExists(marker_path)) {
LOG(WARNING) << "Failure in deleting profile data. Profile:" << info.name
<< " error:" << static_cast<int>(file.error_details());
}
} }
void TryNukeProfileFromDisk(const ProfileInfo& info) { void TryNukeProfileFromDisk(const ProfileInfo& info) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment