Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5)

Unified Diff: sql/error_delegate_util.cc

Issue 2107493002: Offer user to send feedback from profile error dialog (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: sky's comments Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: sql/error_delegate_util.cc
diff --git a/sql/error_delegate_util.cc b/sql/error_delegate_util.cc
index 37fe006947e0afcd8e8f329d62666fef5b287983..2c232aafe35da48eee7ec1e6ad510762fb620e05 100644
--- a/sql/error_delegate_util.cc
+++ b/sql/error_delegate_util.cc
@@ -4,6 +4,7 @@
#include "sql/error_delegate_util.h"
+#include "base/strings/stringprintf.h"
#include "third_party/sqlite/sqlite3.h"
namespace sql {
@@ -77,4 +78,16 @@ bool IsErrorCatastrophic(int error) {
return false;
}
+void AppendCorruptFileInfoToDiagnostics(
+ const base::FilePath& corrupted_file_path,
+ std::string* diagnostics) {
+ DCHECK(diagnostics);
+
+ const std::string corrupted_file_name =
+ corrupted_file_path.DirName().BaseName().AsUTF8Unsafe() + "/" +
+ corrupted_file_path.BaseName().AsUTF8Unsafe();
+ base::StringAppendF(diagnostics, "Corrupted file: %s\n",
+ corrupted_file_name.c_str());
+}
+
} // namespace sql

Powered by Google App Engine
This is Rietveld 408576698