* [PATCH BlueZ] Include UUID in output @ 2016-08-29 9:14 Per Thomas Jahr 2016-08-29 9:14 ` [PATCH BlueZ] client: Include UUID when listing attributes Per Thomas Jahr 0 siblings, 1 reply; 3+ messages in thread From: Per Thomas Jahr @ 2016-08-29 9:14 UTC (permalink / raw) To: linux-bluetooth; +Cc: Per Thomas Jahr Added UUID in the output when listing attributes. This makes it more convenient to work with as it gives a mapping between UUID and attribute id. Per Thomas Jahr (1): client: Include UUID when listing attributes client/gatt.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) -- 2.5.5 ^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH BlueZ] client: Include UUID when listing attributes 2016-08-29 9:14 [PATCH BlueZ] Include UUID in output Per Thomas Jahr @ 2016-08-29 9:14 ` Per Thomas Jahr 2016-08-29 9:31 ` Johan Hedberg 0 siblings, 1 reply; 3+ messages in thread From: Per Thomas Jahr @ 2016-08-29 9:14 UTC (permalink / raw) To: linux-bluetooth; +Cc: Per Thomas Jahr Show the full UUID for services, characteristics and descriptors. --- client/gatt.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/client/gatt.c b/client/gatt.c index fee1cf9..201d668 100644 --- a/client/gatt.c +++ b/client/gatt.c @@ -75,12 +75,13 @@ static void print_service(GDBusProxy *proxy, const char *description) if (!text) text = uuid; - rl_printf("%s%s%s%s Service\n\t%s\n\t%s\n", + rl_printf("%s%s%s%s Service\n\t%s\n\t%s\n\t%s\n", description ? "[" : "", description ? : "", description ? "] " : "", primary ? "Primary" : "Secondary", - g_dbus_proxy_get_path(proxy), + g_dbus_proxy_get_path(proxy), + uuid, text); } @@ -118,12 +119,13 @@ static void print_characteristic(GDBusProxy *proxy, const char *description) if (!text) text = uuid; - rl_printf("%s%s%sCharacteristic\n\t%s\n\t%s\n", + rl_printf("%s%s%sCharacteristic\n\t%s\n\t%s\n\t%s\n", description ? "[" : "", description ? : "", description ? "] " : "", g_dbus_proxy_get_path(proxy), - text); + uuid, + text); } static gboolean characteristic_is_child(GDBusProxy *characteristic) @@ -186,12 +188,13 @@ static void print_descriptor(GDBusProxy *proxy, const char *description) if (!text) text = uuid; - rl_printf("%s%s%sDescriptor\n\t%s\n\t%s\n", + rl_printf("%s%s%sDescriptor\n\t%s\n\t%s\n\t%s\n", description ? "[" : "", description ? : "", description ? "] " : "", g_dbus_proxy_get_path(proxy), - text); + uuid, + text); } static gboolean descriptor_is_child(GDBusProxy *characteristic) -- 2.5.5 ^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH BlueZ] client: Include UUID when listing attributes 2016-08-29 9:14 ` [PATCH BlueZ] client: Include UUID when listing attributes Per Thomas Jahr @ 2016-08-29 9:31 ` Johan Hedberg 0 siblings, 0 replies; 3+ messages in thread From: Johan Hedberg @ 2016-08-29 9:31 UTC (permalink / raw) To: Per Thomas Jahr; +Cc: linux-bluetooth Hi Per, On Mon, Aug 29, 2016, Per Thomas Jahr wrote: > Show the full UUID for services, characteristics and descriptors. > --- > client/gatt.c | 15 +++++++++------ > 1 file changed, 9 insertions(+), 6 deletions(-) The general idea is fine with me but you've managed to change the whitespace to something incompatible with the coding style - this needs to be fixed before the patch is merged. I'd also suggest that you provide some sample output of your changes in the commit message so that reviewers can easily see how the result looks like in practice. > diff --git a/client/gatt.c b/client/gatt.c > index fee1cf9..201d668 100644 > --- a/client/gatt.c > +++ b/client/gatt.c > @@ -75,12 +75,13 @@ static void print_service(GDBusProxy *proxy, const char *description) > if (!text) > text = uuid; > > - rl_printf("%s%s%s%s Service\n\t%s\n\t%s\n", > + rl_printf("%s%s%s%s Service\n\t%s\n\t%s\n\t%s\n", Here the indentation of rl_printf has changed from a tab to spaces. > description ? "[" : "", > description ? : "", > description ? "] " : "", > primary ? "Primary" : "Secondary", > - g_dbus_proxy_get_path(proxy), > + g_dbus_proxy_get_path(proxy), > + uuid, Here the indentation is also spaces when it should be tabs. Also, you can put 'text' on the same line as uuid to save some vertical space. > @@ -118,12 +119,13 @@ static void print_characteristic(GDBusProxy *proxy, const char *description) > if (!text) > text = uuid; > > - rl_printf("%s%s%sCharacteristic\n\t%s\n\t%s\n", > + rl_printf("%s%s%sCharacteristic\n\t%s\n\t%s\n\t%s\n", > description ? "[" : "", > description ? : "", > description ? "] " : "", > g_dbus_proxy_get_path(proxy), > - text); > + uuid, > + text); Same thing here. > @@ -186,12 +188,13 @@ static void print_descriptor(GDBusProxy *proxy, const char *description) > if (!text) > text = uuid; > > - rl_printf("%s%s%sDescriptor\n\t%s\n\t%s\n", > + rl_printf("%s%s%sDescriptor\n\t%s\n\t%s\n\t%s\n", > description ? "[" : "", > description ? : "", > description ? "] " : "", > g_dbus_proxy_get_path(proxy), > - text); > + uuid, > + text); And here. Once these issues are fixed the patch should be good to go in (at least on my behalf). Johan ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2016-08-29 9:31 UTC | newest] Thread overview: 3+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2016-08-29 9:14 [PATCH BlueZ] Include UUID in output Per Thomas Jahr 2016-08-29 9:14 ` [PATCH BlueZ] client: Include UUID when listing attributes Per Thomas Jahr 2016-08-29 9:31 ` Johan Hedberg
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).