Author: agrundman
Date: Tue May 25 08:20:41 2010
New Revision: 8813

URL: http://svn.slimdevices.com/jive?rev=8813&view=rev
Log:
Fixed bug 10801, the samplerate changing logic in portaudio was broken

Modified:
    7.5/trunk/squeezeplay/src/squeezeplay/src/audio/decode/decode_portaudio.c

Modified: 
7.5/trunk/squeezeplay/src/squeezeplay/src/audio/decode/decode_portaudio.c
URL: 
http://svn.slimdevices.com/jive/7.5/trunk/squeezeplay/src/squeezeplay/src/audio/decode/decode_portaudio.c?rev=8813&r1=8812&r2=8813&view=diff
==============================================================================
--- 7.5/trunk/squeezeplay/src/squeezeplay/src/audio/decode/decode_portaudio.c 
(original)
+++ 7.5/trunk/squeezeplay/src/squeezeplay/src/audio/decode/decode_portaudio.c 
Tue May 25 08:20:41 2010
@@ -43,6 +43,7 @@
        bool_t reached_start_point;
        Uint8 *outputArray = (u8_t *)outputBuffer;
        u32_t delay;
+       int ret = paContinue;
 
        if (statusFlags & (paOutputUnderflow | paOutputOverflow)) {
                LOG_DEBUG(log_audio_output, "pa status %x\n", (unsigned 
int)statusFlags);
@@ -177,7 +178,9 @@
 
        reached_start_point = decode_check_start_point();
        if (reached_start_point && decode_audio->track_sample_rate != 
stream_sample_rate) {
+               LOG_DEBUG(log_audio_output, "Sample rate changed from %d to 
%d\n", stream_sample_rate, decode_audio->track_sample_rate);
                decode_audio->set_sample_rate = decode_audio->track_sample_rate;
+               ret = paComplete; // will trigger the finished callback to 
change the samplerate
        }
 
  mixin_effects:
@@ -186,7 +189,7 @@
 
        decode_audio_unlock();
 
-       return paContinue;
+       return ret;
 }
 
 

_______________________________________________
Jive-checkins mailing list
[email protected]
http://lists.slimdevices.com/mailman/listinfo/jive-checkins

Reply via email to