linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Luiz Augusto von Dentz <luiz.dentz@gmail.com>
To: Inga Stotland <ingas@codeaurora.org>
Cc: linux-bluetooth@vger.kernel.org, johan.hedberg@gmail.com,
	marcel@holtmann.org, rshaffer@codeaurora.org
Subject: Re: [PATCH 3/3] Extended support for generating dictionary value of service UUIDs
Date: Thu, 8 Jul 2010 14:36:34 +0300	[thread overview]
Message-ID: <AANLkTinzhNe3-U_wTH3TJIANn6JNgnd7yOp07Ex3axeU@mail.gmail.com> (raw)
In-Reply-To: <1278540518-18620-4-git-send-email-ingas@codeaurora.org>

Hi,

On Thu, Jul 8, 2010 at 1:08 AM, Inga Stotland <ingas@codeaurora.org> wrote:
> ---
> =A0src/adapter.c =A0| =A0103 ++++++++++++++++++++++++++++++++++++++++++++=
+++++++++--
> =A0src/adapter.h =A0| =A0 =A04 +-
> =A0src/dbus-hci.c | =A0 =A07 ++--
> =A0src/sdpd.h =A0 =A0 | =A0 =A02 +
> =A04 files changed, 107 insertions(+), 9 deletions(-)
>
> diff --git a/src/adapter.c b/src/adapter.c
> index 8a05356..9be12e7 100644
> --- a/src/adapter.c
> +++ b/src/adapter.c
> @@ -2716,6 +2716,7 @@ static void append_dict_valist(DBusMessageIter *ite=
r,
> =A0 =A0 =A0 =A0DBusMessageIter dict;
> =A0 =A0 =A0 =A0const char *key;
> =A0 =A0 =A0 =A0int type;
> + =A0 =A0 =A0 int n_elements;
> =A0 =A0 =A0 =A0void *val;
>
> =A0 =A0 =A0 =A0dbus_message_iter_open_container(iter, DBUS_TYPE_ARRAY,
> @@ -2727,7 +2728,12 @@ static void append_dict_valist(DBusMessageIter *it=
er,
> =A0 =A0 =A0 =A0while (key) {
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0type =3D va_arg(var_args, int);
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0val =3D va_arg(var_args, void *);
> - =A0 =A0 =A0 =A0 =A0 =A0 =A0 dict_append_entry(&dict, key, type, val);
> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 if (type =3D=3D DBUS_TYPE_ARRAY) {
> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 n_elements =3D va_arg(var_a=
rgs, int);
> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 if (n_elements > 0)
> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 dict_append=
_array(&dict, key, DBUS_TYPE_STRING, val, n_elements);
> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 } else
> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 dict_append_entry(&dict, ke=
y, type, val);
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0key =3D va_arg(var_args, char *);
> =A0 =A0 =A0 =A0}

Maybe you should separate this from the rest since they will probably
be more use of arrays in dictionaries in the future.

--=20
Luiz Augusto von Dentz
Computer Engineer

  reply	other threads:[~2010-07-08 11:36 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-07 22:08 [PATCH v2 0/3] Enhanced support for extended inquiry response Inga Stotland
2010-07-07 22:08 ` [PATCH 1/3] Support for adding UUID128 to " Inga Stotland
2010-07-08 17:17   ` Marcel Holtmann
2010-07-09 17:03     ` Ron Shaffer
2010-07-09 17:35       ` Marcel Holtmann
2010-07-30 19:13         ` Copyrights and Legal header ingas
2010-07-30 21:38           ` Marcel Holtmann
2010-07-07 22:08 ` [PATCH 2/3] Update EIR whenever record is added or removed Inga Stotland
2010-07-08 17:21   ` Marcel Holtmann
2010-07-07 22:08 ` [PATCH 3/3] Extended support for generating dictionary value of service UUIDs Inga Stotland
2010-07-08 11:36   ` Luiz Augusto von Dentz [this message]
2010-07-08 17:23   ` Marcel Holtmann

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=AANLkTinzhNe3-U_wTH3TJIANn6JNgnd7yOp07Ex3axeU@mail.gmail.com \
    --to=luiz.dentz@gmail.com \
    --cc=ingas@codeaurora.org \
    --cc=johan.hedberg@gmail.com \
    --cc=linux-bluetooth@vger.kernel.org \
    --cc=marcel@holtmann.org \
    --cc=rshaffer@codeaurora.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 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).