Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp1012038pxj; Thu, 17 Jun 2021 20:08:21 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzl3cjD6I3R8VzOi6h+Adt+rmSPzcFcrElVKaajasCufH/01jYYfw0bkfVO8WN6yWk7S8sP X-Received: by 2002:a17:907:7848:: with SMTP id lb8mr8869770ejc.494.1623985701147; Thu, 17 Jun 2021 20:08:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623985701; cv=none; d=google.com; s=arc-20160816; b=Xq806OqpEB1zVmzkhW+W77aolxibJh8bvjKKUWrbBpHXVmVdC14wb2E9lGSf61Ry+u WGH5rNO7/KriVFCutm0i/6DdLej298+1qemY1um7IKLiBfsgMwSnjuN/xm+Zpgz5peyc 4ezBl3KA99uFKjwkM8Eh20KoxZ5S2YvT3Qpd6d5fhT9X88+T6njmgHUMhkv49ZLDTTMA vbTHyazUdfrJXxQw3ZYeU3pg7TPT35YPbG5UwRHLUiFfn4Ci7gUryivt+vdjjDLQGjYL K2F/OMz4koz/HSa8obzUjfYxGuxjWh3nQPlM8SZ5rTeEX5ca/H7vdi8A8hDCmZyyX12x nmyw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=7zDDBUcMb4xmnGPjaJ5I+6BNcJkydoiN3r/QOjWXtXo=; b=zMsE065AkMtk6xwa8wMYb8mXgzIVbJLPfAW8DMF2dJJezy/yVRsmhKObaCNgp1QhTL a4MCuLzcFsnYiHTeV3BARGuePfueXyw8WW45lxWmBxunP7TyPl27V7URYrggBdQQKulh Zlbgcq2N4/+l0mTOQ80PHpnUsSGTLH9bDnDSO1wRoA5IuJlRiWcN5VWIq2AA0wzXoRkC qtk3FuHtCRU33BR2esakbpxaqcgwXa3x+uf7DWe5aeaWXMnQRu66qohTR+veNKekbiJr 09hlEnlvuRZUBhHSlz1TvLDiQ2pP4EzOq5LxEWQou6P+3EtsevQlHeBAu04Hx0DV1QZE jNEg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=kPJTBkOT; spf=pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id w8si7578648edl.304.2021.06.17.20.07.41; Thu, 17 Jun 2021 20:08:21 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=kPJTBkOT; spf=pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233149AbhFRATx (ORCPT + 99 others); Thu, 17 Jun 2021 20:19:53 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53918 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232755AbhFRATx (ORCPT ); Thu, 17 Jun 2021 20:19:53 -0400 Received: from mail-pf1-x429.google.com (mail-pf1-x429.google.com [IPv6:2607:f8b0:4864:20::429]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4DCC3C06175F for ; Thu, 17 Jun 2021 17:17:44 -0700 (PDT) Received: by mail-pf1-x429.google.com with SMTP id x16so6287950pfa.13 for ; Thu, 17 Jun 2021 17:17:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=7zDDBUcMb4xmnGPjaJ5I+6BNcJkydoiN3r/QOjWXtXo=; b=kPJTBkOTxN/i29stlgwWZDE/yZme0WPMa/9ZwlS5Mnw/uWQYhiUMKdTvVkaaAj25xX zV9aFuMMd9MwJVDtxSvucy2Ct6lIZTolQjPKXh5yAe5NKAZt8BJ/q3fyeWwN1+F5Z8KT ZfLbILtVcjNDlYU7RdWG+h2ipfX94gEMEacpc= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=7zDDBUcMb4xmnGPjaJ5I+6BNcJkydoiN3r/QOjWXtXo=; b=i6FSw9mNddjyS/Pu67/n3ISfLXhAPxPzXsZYEyhIr2/RHSmxM4S4g+xcM9Akq/3c0b brkmRCESq2hrBpexYed2c+h2hX5JEJOrlna+8sZeqd5+1E2IslI+ZF1Qt/mxgGHG3jZm RnX2wPlpd22GyTxTDP26zXNPx9GaFpKsb6yex/ybgg1ZT2zyxclodgeueihikkWW3pbl 9xIIZUfqB3cMpZFkpyDwfPaGvMAhB4v0w5fVLjbHQAte85WqwS3nuQkTlSOukrO9M+ju TpYgTPkTm2jHMW/ntwXyafoiQS3kqfDYBTzMXyoHgNt9vZb7zwb8qTj/tIGDNNl2xPwX sqYg== X-Gm-Message-State: AOAM5313cg6E+5zolQSOwLSnOo1tVdY+9t7OHMRodSgdrhmcFNzmlARA 9dsHoV6hxjpBrZsDX0ygyW62hXbdxWyUMA== X-Received: by 2002:a63:a54b:: with SMTP id r11mr223953pgu.43.1623975463396; Thu, 17 Jun 2021 17:17:43 -0700 (PDT) Received: from localhost ([2620:15c:202:201:d75:da94:7930:935d]) by smtp.gmail.com with UTF8SMTPSA id y13sm6419808pgp.16.2021.06.17.17.17.42 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 17 Jun 2021 17:17:43 -0700 (PDT) From: Miao-chen Chou To: Bluetooth Kernel Mailing List Cc: Marcel Holtmann , Alain Michaud , Luiz Augusto von Dentz , Howard Chung , Miao-chen Chou Subject: [BlueZ PATCH v1 3/3] client: Print error code for connect methods Date: Thu, 17 Jun 2021 17:16:02 -0700 Message-Id: <20210617170013.BlueZ.v1.3.I226fdcdd12b13e4875c8cd03b42fc52283920cc4@changeid> X-Mailer: git-send-email 2.32.0.288.g62a8d224e6-goog In-Reply-To: <20210618001559.1284204-1-mcchou@chromium.org> References: <20210618001559.1284204-1-mcchou@chromium.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org The following steps were performed. - Issuing repeated commands to connect the same BLE device. - Verifying the print in bluetoothctl console Reviewed-by: Alain Michaud Reviewed-by: Howard Chung --- client/main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/client/main.c b/client/main.c index da877b546..488a24bf6 100644 --- a/client/main.c +++ b/client/main.c @@ -1949,7 +1949,8 @@ static void connect_reply(DBusMessage *message, void *user_data) dbus_error_init(&error); if (dbus_set_error_from_message(&error, message) == TRUE) { - bt_shell_printf("Failed to connect: %s\n", error.name); + bt_shell_printf("Failed to connect: %s %s\n", error.name, + error.message); dbus_error_free(&error); return bt_shell_noninteractive_quit(EXIT_FAILURE); } -- 2.32.0.288.g62a8d224e6-goog