[pulseaudio-commits] r1482 - /branches/lennart/src/pulsecore/protocol-simple.c

svnmailer-noreply at 0pointer.de svnmailer-noreply at 0pointer.de
Thu Jun 14 13:13:45 PDT 2007


Author: lennart
Date: Thu Jun 14 22:13:44 2007
New Revision: 1482

URL: http://0pointer.de/cgi-bin/viewcvs.cgi?rev=3D1482&root=3Dpulseaudio&vi=
ew=3Drev
Log:
use pa_memblockq_push_align() instead of pa_memblockq_push() to deal with u=
naligned data coming from clients

Modified:
    branches/lennart/src/pulsecore/protocol-simple.c

Modified: branches/lennart/src/pulsecore/protocol-simple.c
URL: http://0pointer.de/cgi-bin/viewcvs.cgi/branches/lennart/src/pulsecore/=
protocol-simple.c?rev=3D1482&root=3Dpulseaudio&r1=3D1481&r2=3D1482&view=3Dd=
iff
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D
--- branches/lennart/src/pulsecore/protocol-simple.c (original)
+++ branches/lennart/src/pulsecore/protocol-simple.c Thu Jun 14 22:13:44 20=
07
@@ -205,8 +205,10 @@
     if (!c->source_output)
         return 0;
 =

-    if (pa_memblockq_peek(c->output_memblockq, &chunk) < 0)
+    if (pa_memblockq_peek(c->output_memblockq, &chunk) < 0) {
+/*         pa_log("peek failed"); */
         return 0;
+    }
 =

     pa_assert(chunk.memblock);
     pa_assert(chunk.length);
@@ -276,7 +278,8 @@
             break;
             =

         case MESSAGE_POST_DATA:
-            pa_memblockq_push(c->output_memblockq, chunk);
+/*             pa_log("got data %u", chunk->length); */
+            pa_memblockq_push_align(c->output_memblockq, chunk);
             do_work(c);
             break;
 =





More information about the pulseaudio-commits mailing list