From: <daniele.biagetti@cblelectronics.com>
To: <linux-bluetooth@vger.kernel.org>
Subject: [PATCH 3/6] tools/mesh-gatt: Fix unwanted return in onoff client model
Date: Fri, 3 Dec 2021 17:02:15 +0100 [thread overview]
Message-ID: <000701d7e85f$23f6c130$6be44390$@cblelectronics.com> (raw)
Replaced the return statement with a warning message in case of
transmission or reception of messages coming from unknown addresses
(such as group addresses)
---
tools/mesh-gatt/onoff-model.c | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/tools/mesh-gatt/onoff-model.c b/tools/mesh-gatt/onoff-model.c
index 1c9676e03..9a4ef6d97 100644
--- a/tools/mesh-gatt/onoff-model.c
+++ b/tools/mesh-gatt/onoff-model.c
@@ -209,8 +209,9 @@ static void cmd_get_status(int argc, char *argv[])
node = node_find_by_addr(target);
- if (!node)
- return;
+ if (!node){
+ bt_shell_printf("Warning: node %4.4x not found in
database\n",target);
+ }
n = mesh_opcode_set(OP_GENERIC_ONOFF_GET, msg);
@@ -237,8 +238,9 @@ static void cmd_set(int argc, char *argv[])
node = node_find_by_addr(target);
- if (!node)
- return;
+ if (!node){
+ bt_shell_printf("Warning: node %4.4x not found in
database\n",target);
+ }
np = read_input_parameters(argc, argv);
if ((np != 1) && (np != 2) &&
--
2.25.1
reply other threads:[~2021-12-03 16:09 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='000701d7e85f$23f6c130$6be44390$@cblelectronics.com' \
--to=daniele.biagetti@cblelectronics.com \
--cc=linux-bluetooth@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.