[pulseaudio-discuss] [PATCH] bluetooth: Don't abort on SBC decoding error
tanu.kaskinen at linux.intel.com
Wed Jan 22 03:26:33 PST 2014
On Sat, 2014-01-18 at 20:14 +1100, James Bunton wrote:
> Hi Tanu,
> Thanks for the quick review! :)
> My mobile phone (Nokia E7 running Symbian Belle Refresh) is connecting
> to pulseaudio/bluez running on my Arch Linux on my Raspberry Pi. Without
> this patch every few minutes pulseaudio will disconnect the stream and
> log "SBC decoding error (-3)". As you can imagine this is quite
> annoying! :)
Yes, I can believe that :) Please add this information to the commit
message too. The commit message should always answer the question "why
is this needed". Here's some more wisdom about commit messages:
> I see what you mean about the timing code being wrong. What does
> pulseaudio use this for? Should I expect to hear some audio glitches
> with the current incorrect code, or is it just for display in a GUI?
It's used for latency reporting. I don't think the latency information
is used much when recording, it's more important for playback
(lip-sync), but of course we still should strive for correct values in
the latency reports. I don't expect that you would hear glitches even if
the latency information is wrong.
> I've modified it to use the number of bytes that sbc_decode reports it
> wrote to the output buffer. Both versions seem to work equally well for
The read_index update is still not quite in the right place.
sbc_decode() is called in a loop, and if it fails at any iteration, then
read_index should not be updated. So, the update should happen after the
> You can see them here:
> Repo URL: http://delx.net.au/git/pulseaudio
> I can submit these as patch files with git-send-email if that's
> preferable for review.
I prefer git send-email.
> Thanks again :)
Thanks for the patches!
More information about the pulseaudio-discuss