According to the patch author, Karl Hegbloom:
"The assertion is incorrectly testing for '==' when logically it
should test for '<='."

BugLink: https://bugs.launchpad.net/bugs/689915
Signed-off-by: David Henningsson <david.hennings...@canonical.com>
---

This is a patch I found attached to a bug in Ubuntu. I don't know
much about bluetooth, and the error was reported against something
around 0.9.22. But I'm sending it here, hoping that one of our
bluetooth people can review and say whether this is correct or not.

 src/modules/bluetooth/module-bluetooth-device.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/modules/bluetooth/module-bluetooth-device.c 
b/src/modules/bluetooth/module-bluetooth-device.c
index e3ec6ae..06c783d 100644
--- a/src/modules/bluetooth/module-bluetooth-device.c
+++ b/src/modules/bluetooth/module-bluetooth-device.c
@@ -999,9 +999,9 @@ static int a2dp_process_push(struct userdata *u) {
             a2dp->frame_length = sbc_get_frame_length(&a2dp->sbc);
 
             pa_assert_fp((size_t) decoded <= to_decode);
-            pa_assert_fp((size_t) decoded == a2dp->frame_length);
+            pa_assert_fp((size_t) decoded <= a2dp->frame_length);
 
-            pa_assert_fp((size_t) written == a2dp->codesize);
+            pa_assert_fp((size_t) written <= a2dp->codesize);
 
             p = (const uint8_t*) p + decoded;
             to_decode -= decoded;
-- 
1.7.9.5

-- 
You received this bug notification because you are a member of Desktop
Packages, which is subscribed to pulseaudio in Ubuntu.
https://bugs.launchpad.net/bugs/689915

Title:
  pulseaudio aborts with assertion decoded == a2dp->frame_length in
  function a2dp_process_push()

Status in “pulseaudio” package in Ubuntu:
  New

Bug description:
  Binary package hint: pulseaudio

  See also ticket: http://pulseaudio.org/ticket/636

  Steps to reproduce:
  1. start pulseaudio daemon
  2. issue a bluez AudioSource?.Connect() dbus call, or use blueman to connect 
the laptop as audio source
  3. daemon aborts with 
      Assertion '(size_t) decoded == a2dp->frame_length' failed at 
modules/bluetooth/module-bluetooth-device.c:1361, function a2dp_process_push(). 
Aborting.

  I have the problem with as source OSX Snow Leopard, and target Ubuntu
  Linux Lucid

  
  Source bitpool settings: 40 
  Pulseaudio version: pulseaudio 0.9.21-63-gd3efa-dirty 

  
  My first suggestion would be to update the bluetooth module, from git.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/pulseaudio/+bug/689915/+subscriptions

-- 
Mailing list: https://launchpad.net/~desktop-packages
Post to     : desktop-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~desktop-packages
More help   : https://help.launchpad.net/ListHelp

Reply via email to