Re: regression in sdp lib

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Szymon,

On Tue, Jun 25, 2013 at 3:54 PM, Szymon Janc <szymon.janc@xxxxxxxxx> wrote:
> Hi Johan,
>
> On Tuesday 25 June 2013 21:48:48 Johan Hedberg wrote:
>> Hi Szymon,
>>
>> On Fri, Jun 21, 2013, Szymon Janc wrote:
>> > commit 'lib: Add range check for SDP_SVC_ATTR_RSP/SDP_SVC_SEARCH_ATTR_RSP'
>> > 1796f00e846561af broke sdp with Nokia BH217 headset.
>>
>> Since there evidently wasn't any progress on this issue and we want to
>> get a new release out (due to also another severe regression) I've gone
>> ahead and simply reverted the original patch. Nevertheless, I'm still
>> looking forward to seeing a proper fix for this issue.
>
> Maybe it would be enough to verify size only if there is no continuation?
>
>                 /* Valid range for rsp_count is 0x0002-0xFFFF */
> -               if (rsp_count < 0x0002) {
> +               if (t->rsp_concat_buf.data_size == 0 && rsp_count < 0x0002) {
>                         t->err = EPROTO;
>
>
> Seems to be working for me but I'm that much familiar sdp code..

I agree this change should work just fine (to my understanding). If
rsp_count is invalid , it will fail with EPROTO and BlueZ will not
issue a continuation SDP request anyway.

Best Regards,
-- 
Anderson Lizardo
Instituto Nokia de Tecnologia - INdT
Manaus - Brazil
--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux