aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatt Ranostay <matt.ranostay@konsulko.com>2018-12-11 01:49:38 -0800
committerMatt Ranostay <matt.ranostay@konsulko.com>2018-12-11 02:04:58 -0800
commita7b32137538def69922d178d7091046a361a6063 (patch)
tree34a2b30736f0978176231d457f5abc3f07e7f13f
parent9c8a34c23726c1bbac9e333da1c37b775d4953f9 (diff)
binding: bluetooth: don't display errors if no error pointer is passedguppy_6.99.3guppy/6.99.36.99.3
There is sometimes when you don't want AFB_ERROR to be displayed on a dbus failure. Example would be in the initial autoconnect attempt on binding startup. Don't display the AFB_ERROR if error pointer that is passed is NULL Bug-AGL: SPEC-1630 SPEC-1986 Change-Id: I2bc1e8575037a8e84721d2c2c369a409986eda43 Signed-off-by: Matt Ranostay <matt.ranostay@konsulko.com>
-rw-r--r--binding/bluetooth-bluez.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/binding/bluetooth-bluez.c b/binding/bluetooth-bluez.c
index fa6d34b..18194d5 100644
--- a/binding/bluetooth-bluez.c
+++ b/binding/bluetooth-bluez.c
@@ -241,8 +241,8 @@ GVariant *bluez_call(struct bluetooth_state *ns,
NULL, error);
bluez_decode_call_error(ns, access_type, path, method,
error);
- if (!reply) {
- if (error && *error)
+ if (!reply && error) {
+ if (*error)
g_dbus_error_strip_remote_error(*error);
AFB_ERROR("Error calling %s%s%s %s method %s",
access_type,