[Pkg-pulseaudio-devel] r114 - in /pulseaudio/trunk/debian: changelog patches/r1431-handle-when-alsa-tweaks-our-sample-spec.patch patches/series
neurocyte-guest at users.alioth.debian.org
neurocyte-guest at users.alioth.debian.org
Thu May 24 21:09:01 UTC 2007
Author: neurocyte-guest
Date: Thu May 24 21:09:01 2007
New Revision: 114
URL: http://svn.debian.org/wsvn/pkg-pulseaudio/?sc=1&rev=114
Log:
Fix bug #423887
Added:
pulseaudio/trunk/debian/patches/r1431-handle-when-alsa-tweaks-our-sample-spec.patch
Modified:
pulseaudio/trunk/debian/changelog
pulseaudio/trunk/debian/patches/series
Modified: pulseaudio/trunk/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-pulseaudio/pulseaudio/trunk/debian/changelog?rev=114&op=diff
==============================================================================
--- pulseaudio/trunk/debian/changelog (original)
+++ pulseaudio/trunk/debian/changelog Thu May 24 21:09:01 2007
@@ -18,8 +18,10 @@
+ Added r1416-r1417-fix-incorrect-assert
+ Added r1422-make-sure-we-report-success-for-SNDCTL_DSP_SETDUPLEX
+ Added r1423-dont-abort-config-loading-when-user-config-cannot-be-loaded
+ * debian/patch: r1431-handle-when-alsa-tweaks-our-sample-spec
+ + Added. Handle frame size changes. (Closes: #423887)
- -- CJ van den Berg <cj at vdbonline.com> Tue, 15 May 2007 16:25:26 +0200
+ -- CJ van den Berg <cj at vdbonline.com> Tue, 15 May 2007 18:18:16 +0200
pulseaudio (0.9.5-7) unstable; urgency=low
Added: pulseaudio/trunk/debian/patches/r1431-handle-when-alsa-tweaks-our-sample-spec.patch
URL: http://svn.debian.org/wsvn/pkg-pulseaudio/pulseaudio/trunk/debian/patches/r1431-handle-when-alsa-tweaks-our-sample-spec.patch?rev=114&op=file
==============================================================================
--- pulseaudio/trunk/debian/patches/r1431-handle-when-alsa-tweaks-our-sample-spec.patch (added)
+++ pulseaudio/trunk/debian/patches/r1431-handle-when-alsa-tweaks-our-sample-spec.patch Thu May 24 21:09:01 2007
@@ -1,0 +1,41 @@
+Handle when ALSA tweaks our sample spec so much that the frame size changes.
+
+From: Pierre Ossman <ossman at fefdeb5f-60dc-0310-8127-8f9354f1896f>
+
+(closes #57).
+
+git-svn-id: svn://svn.0pointer.net/pulseaudio/trunk@1431 fefdeb5f-60dc-0310-8127-8f9354f1896f
+---
+
+ src/modules/module-alsa-sink.c | 11 +++++++++--
+ 1 files changed, 9 insertions(+), 2 deletions(-)
+
+diff --git a/src/modules/module-alsa-sink.c b/src/modules/module-alsa-sink.c
+index 6ff9a6e..df04281 100644
+--- a/src/modules/module-alsa-sink.c
++++ b/src/modules/module-alsa-sink.c
+@@ -155,8 +155,12 @@ static void do_write(struct userdata *u) {
+ else
+ memchunk = &u->memchunk;
+ }
+-
+- assert(memchunk->memblock && memchunk->memblock->data && memchunk->length && memchunk->memblock->length && (memchunk->length % u->frame_size) == 0);
++
++ assert(memchunk->memblock);
++ assert(memchunk->memblock->data);
++ assert(memchunk->length);
++ assert(memchunk->memblock->length);
++ assert((memchunk->length % u->frame_size) == 0);
+
+ if ((frames = snd_pcm_writei(u->pcm_handle, (uint8_t*) memchunk->memblock->data + memchunk->index, memchunk->length / u->frame_size)) < 0) {
+ if (frames == -EAGAIN)
+@@ -412,6 +416,9 @@ int pa__init(pa_core *c, pa_module*m) {
+ goto fail;
+ }
+
++ /* ALSA might tweak the sample spec, so recalculate the frame size */
++ frame_size = pa_frame_size(&ss);
++
+ if (ss.channels != map.channels)
+ /* Seems ALSA didn't like the channel number, so let's fix the channel map */
+ pa_channel_map_init_auto(&map, ss.channels, PA_CHANNEL_MAP_ALSA);
Modified: pulseaudio/trunk/debian/patches/series
URL: http://svn.debian.org/wsvn/pkg-pulseaudio/pulseaudio/trunk/debian/patches/series?rev=114&op=diff
==============================================================================
--- pulseaudio/trunk/debian/patches/series (original)
+++ pulseaudio/trunk/debian/patches/series Thu May 24 21:09:01 2007
@@ -13,5 +13,6 @@
r1416-r1417-fix-incorrect-assert.patch
r1422-make-sure-we-report-success-for-SNDCTL_DSP_SETDUPLEX.patch
r1423-dont-abort-config-loading-when-user-config-cannot-be-loaded.patch
+r1431-handle-when-alsa-tweaks-our-sample-spec.patch
r1433-handle-suspended-alsa-devices.patch
r1437-add-support-for-SNDCTL_DSP_SETTRIGGER.patch
More information about the Pkg-pulseaudio-devel
mailing list