All of lore.kernel.org
 help / color / mirror / Atom feed
From: Angela Bartholomaus <angelab@codeaurora.org>
To: linux-bluetooth@vger.kernel.org
Cc: rshaffer@codeaurora.org, marcel@holtmann.org,
	johan.hedberg@gmail.com,
	Angela Bartholomaus <angelab@codeaurora.org>
Subject: [PATCH 1/4] Send an Invalid PDU Size Error Response for Service Search Req
Date: Tue, 24 Aug 2010 15:14:17 -0700	[thread overview]
Message-ID: <1282688060-10727-2-git-send-email-angelab@codeaurora.org> (raw)
In-Reply-To: <1282688060-10727-1-git-send-email-angelab@codeaurora.org>

Send error code for an SDP request received with an invalid PDU Size
---
 src/sdpd-request.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/sdpd-request.c b/src/sdpd-request.c
index d56ffc2..cc9fe82 100644
--- a/src/sdpd-request.c
+++ b/src/sdpd-request.c
@@ -367,7 +367,7 @@ static int service_search_req(sdp_req_t *req, sdp_buf_t *buf)
 	mlen = scanned + sizeof(uint16_t) + 1;
 	// ensure we don't read past buffer
 	if (plen < mlen || plen != mlen + *(uint8_t *)(pdata+sizeof(uint16_t))) {
-		status = SDP_INVALID_SYNTAX;
+		status = SDP_INVALID_PDU_SIZE;
 		goto done;
 	}
 
-- 
1.7.0.2
--
Angela Bartholomaus
Sent by an employee of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum.

  reply	other threads:[~2010-08-24 22:14 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-24 22:14 [PATCH 0/4] Fix error reporting for SDP Requests Angela Bartholomaus
2010-08-24 22:14 ` Angela Bartholomaus [this message]
2010-08-24 22:14 ` [PATCH 2/4] Send an Invalid PDU Size Error Response for Service Attr Req Angela Bartholomaus
2010-08-24 22:14 ` [PATCH 3/4] Send an Invalid PDU Size Error Resp for Service Attr Search Req Angela Bartholomaus
2010-08-24 22:14 ` [PATCH 4/4] Send Invalid Syntax Error if Resp Size Less Than 0x07 Angela Bartholomaus
2010-08-24 22:21 ` [PATCH 0/4] Fix error reporting for SDP Requests Marcel Holtmann
2010-08-24 22:55   ` angelab
2010-08-24 23:15     ` 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=1282688060-10727-2-git-send-email-angelab@codeaurora.org \
    --to=angelab@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 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.