Index: dbus/object_proxy.cc |
diff --git a/dbus/object_proxy.cc b/dbus/object_proxy.cc |
index 5167cab76035ee50ec7a9f49082e9a6656f76513..8e4f18e09e5d955e02d390b1dd60677fd9e796f3 100644 |
--- a/dbus/object_proxy.cc |
+++ b/dbus/object_proxy.cc |
@@ -24,6 +24,7 @@ namespace dbus { |
namespace { |
const char kErrorServiceUnknown[] = "org.freedesktop.DBus.Error.ServiceUnknown"; |
+const char kErrorObjectUnknown[] = "org.freedesktop.DBus.Error.UnknownObject"; |
// Used for success ratio histograms. 1 for success, 0 for failure. |
const int kSuccessRatioHistogramMaxValue = 2; |
@@ -561,8 +562,15 @@ void ObjectProxy::LogMethodCallFailure( |
const base::StringPiece& method_name, |
const base::StringPiece& error_name, |
const base::StringPiece& error_message) const { |
- if (ignore_service_unknown_errors_ && error_name == kErrorServiceUnknown) |
+ if (ignore_service_unknown_errors_ && |
+ (error_name == kErrorServiceUnknown || error_name == kErrorObjectUnknown)) |
return; |
+ logging::LogSeverity severity = logging::LOG_ERROR; |
+ // "UnknownObject" indicates that an object or service is no longer available, |
+ // e.g. a Shill network service has gone out of range. Treat these as warnings |
+ // not errors. |
+ if (error_name == kErrorObjectUnknown) |
+ severity = logging::LOG_WARNING; |
hashimoto
2014/08/08 02:46:31
This variable looks unused and it seems we never r
hashimoto
2014/08/08 07:28:46
Sorry, I dismissed "ignore_service_unknown_errors_
stevenjb
2014/08/08 16:31:58
Oops, thanks for catching, fixed.
|
LOG(ERROR) << "Failed to call method: " |
<< interface_name << "." << method_name |
<< ": object_path= " << object_path_.value() |