Linux bluetooth development
 help / color / mirror / Atom feed
From: Bartosz Szatkowski <bulislaw@linux.com>
To: linux-bluetooth@vger.kernel.org
Cc: Bartosz Szatkowski <bulislaw@linux.com>
Subject: [PATCH v2] Fix endian conversion for appparams in pbap client
Date: Sun, 15 May 2011 12:37:41 +0200	[thread overview]
Message-ID: <1305455861-26395-1-git-send-email-bulislaw@linux.com> (raw)

---
 client/pbap.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/client/pbap.c b/client/pbap.c
index 837419c..589b1ca 100644
--- a/client/pbap.c
+++ b/client/pbap.c
@@ -312,7 +312,7 @@ static void read_return_apparam(struct session_data *session,
 			if (hdr->len == PHONEBOOKSIZE_LEN) {
 				guint16 val;
 				memcpy(&val, hdr->val, sizeof(val));
-				*phone_book_size = val;
+				*phone_book_size = get_be16(&val);
 			}
 			break;
 		case NEWMISSEDCALLS_TAG:
-- 
1.7.5.rc3


             reply	other threads:[~2011-05-15 10:37 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-05-15 10:37 Bartosz Szatkowski [this message]
2011-05-15 11:49 ` [PATCH v2] Fix endian conversion for appparams in pbap client Johan Hedberg

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=1305455861-26395-1-git-send-email-bulislaw@linux.com \
    --to=bulislaw@linux.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox