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

Unified Diff: chromeos/dbus/debug_daemon_client.cc

Issue 26536002: chrome://crashes: add a link on CrOS for triggering crash uploading (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 2 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: chromeos/dbus/debug_daemon_client.cc
diff --git a/chromeos/dbus/debug_daemon_client.cc b/chromeos/dbus/debug_daemon_client.cc
index c9b760fafd90d5465dd6b4ce51833170c3c7390f..3dd2ed909433c4773c19d155cc1ee09d02caa077 100644
--- a/chromeos/dbus/debug_daemon_client.cc
+++ b/chromeos/dbus/debug_daemon_client.cc
@@ -309,7 +309,7 @@ class DebugDaemonClientImpl : public DebugDaemonClient {
debugdaemon_proxy_->CallMethod(
&method_call,
dbus::ObjectProxy::TIMEOUT_USE_DEFAULT,
- base::Bind(&DebugDaemonClientImpl::OnStartSystemTracing,
+ base::Bind(&DebugDaemonClientImpl::OnStartMethod,
weak_ptr_factory_.GetWeakPtr()));
}
@@ -396,6 +396,16 @@ class DebugDaemonClientImpl : public DebugDaemonClient {
callback));
}
+ virtual void UploadCrashes() OVERRIDE {
+ dbus::MethodCall method_call(debugd::kDebugdInterface,
+ debugd::kUploadCrashes);
+ debugdaemon_proxy_->CallMethod(
+ &method_call,
+ dbus::ObjectProxy::TIMEOUT_USE_DEFAULT,
+ base::Bind(&DebugDaemonClientImpl::OnStartMethod,
+ weak_ptr_factory_.GetWeakPtr()));
+ }
+
protected:
virtual void Init(dbus::Bus* bus) OVERRIDE {
debugdaemon_proxy_ =
@@ -551,10 +561,10 @@ class DebugDaemonClientImpl : public DebugDaemonClient {
return OnGetAllLogs(callback, response);
}
- // Called when a response for StartSystemTracing() is received.
- void OnStartSystemTracing(dbus::Response* response) {
+ // Called when a response for a simple start is received.
+ void OnStartMethod(dbus::Response* response) {
if (!response) {
- LOG(ERROR) << "Failed to request systrace start";
+ LOG(ERROR) << "Failed to request start";
return;
}
}
@@ -688,13 +698,11 @@ class DebugDaemonClientStubImpl : public DebugDaemonClient {
FROM_HERE,
base::Bind(callback, true, user_logs));
}
-
virtual void TestICMP(const std::string& ip_address,
const TestICMPCallback& callback) OVERRIDE {
base::MessageLoop::current()->PostTask(FROM_HERE,
base::Bind(callback, false, ""));
}
-
virtual void TestICMPWithOptions(
const std::string& ip_address,
const std::map<std::string, std::string>& options,
@@ -702,6 +710,7 @@ class DebugDaemonClientStubImpl : public DebugDaemonClient {
base::MessageLoop::current()->PostTask(FROM_HERE,
base::Bind(callback, false, ""));
}
+ virtual void UploadCrashes() OVERRIDE {}
};
DebugDaemonClient::DebugDaemonClient() {
« chrome/browser/ui/webui/crashes_ui.cc ('K') | « chromeos/dbus/debug_daemon_client.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698