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

Unified Diff: tools/tool_support.cc

Issue 1119783005: win: get tools/crashpad_database_util mostly working (Closed) Base URL: https://chromium.googlesource.com/crashpad/crashpad@master
Patch Set: fixes Created 5 years, 7 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
« no previous file with comments | « tools/tool_support.h ('k') | tools/tools.gyp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/tool_support.cc
diff --git a/tools/tool_support.cc b/tools/tool_support.cc
index 175fa431df1c01328af21e7684c0013bc945c03c..f4960246bb8638c33a292e6cdafff89ee80a34cc 100644
--- a/tools/tool_support.cc
+++ b/tools/tool_support.cc
@@ -21,31 +21,50 @@
namespace crashpad {
// static
-void ToolSupport::Version(const std::string& me) {
+void ToolSupport::Version(const base::FilePath& me) {
fprintf(stderr,
- "%s (%s) %s\n%s\n",
- me.c_str(),
+ "%s" PRFilePath " (%s) %s\n%s\n",
+ me.value().c_str(),
PACKAGE_NAME,
PACKAGE_VERSION,
PACKAGE_COPYRIGHT);
}
// static
-void ToolSupport::UsageTail(const std::string& me) {
+void ToolSupport::UsageTail(const base::FilePath& me) {
fprintf(stderr,
- "\nReport %s bugs to\n%s\n%s home page: <%s>\n",
- me.c_str(),
+ "\nReport %" PRFilePath " bugs to\n%s\n%s home page: <%s>\n",
+ me.value().c_str(),
PACKAGE_BUGREPORT,
PACKAGE_NAME,
PACKAGE_URL);
}
// static
-void ToolSupport::UsageHint(const std::string& me, const char* hint) {
+void ToolSupport::UsageHint(const base::FilePath& me, const char* hint) {
if (hint) {
- fprintf(stderr, "%s: %s\n", me.c_str(), hint);
+ fprintf(stderr, "%" PRFilePath ": %s\n", me.value().c_str(), hint);
}
- fprintf(stderr, "Try '%s --help' for more information.\n", me.c_str());
+ fprintf(stderr,
+ "Try '%" PRFilePath " --help' for more information.\n",
+ me.value().c_str());
+}
+
+#if defined(OS_POSIX)
+// static
+void ToolSupport::Version(const std::string& me) {
+ Version(base::FilePath(me));
+}
+
+// static
+void ToolSupport::UsageTail(const std::string& me) {
+ UsageTail(base::FilePath(me));
+}
+
+// static
+void ToolSupport::UsageHint(const std::string& me, const char* hint) {
+ UsageHint(base::FilePath(me), hint);
}
+#endif // OS_POSIX
} // namespace crashpad
« no previous file with comments | « tools/tool_support.h ('k') | tools/tools.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698