test/avdtp: avdtp source only request to send once

This commit is contained in:
Matthias Ringwald 2017-05-29 12:31:35 +02:00
parent 9562527120
commit f45a46c362

View File

@ -306,9 +306,9 @@ static void avdtp_fill_audio_buffer_timeout_handler(btstack_timer_source_t * tim
context->time_audio_data_sent = now;
context->samples_ready += num_samples;
if (!context->sbc_ready_to_send){
fill_sbc_audio_buffer(context);
}
if (!context->sbc_ready_to_send) return;
fill_sbc_audio_buffer(context);
if ((context->sbc_storage_count + btstack_sbc_encoder_sbc_buffer_length()) > context->max_media_payload_size){
// schedule sending