[Asterisk-code-review] audiohook.c: Difference in read/write rates caused continuou... (asterisk[11])

Kevin Harwell asteriskteam at digium.com
Wed May 20 12:34:24 CDT 2015


Kevin Harwell has posted comments on this change.

Change subject: audiohook.c: Difference in read/write rates caused continuous buffer resets
......................................................................


Patch Set 5:

(2 comments)

https://gerrit.asterisk.org/#/c/462/5/main/audiohook.c
File main/audiohook.c:

Line 438: 	audiohook_list->list_internal_samp_rate = DEFAULT_INTERNAL_RATE;
> Couldn't you invoke audiohook_check_rate to get the new sample rate?
It still wouldn't get the correct rate. A list's internal rate always chooses the higher between its own rate and a given rate. If the current rate is being driven by an audiohook that wanted a higher rate then when this audiohook is removed the list's rate would remain at that level when it should be lower and with no way to lower it since any rate compared against it would be lower.

By setting it back to the lowest rate it can recalulate the new highest rate.


Line 889: 	audiohook_list_check_rate(audiohook_list, frame);
> Yeah, I meant determining the new rate as it loops through the audiohooks a
okay I will see what I can do.


-- 
To view, visit https://gerrit.asterisk.org/462
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Idab4dfef068a7922c09cc631dda27bc920a6c76f
Gerrit-PatchSet: 5
Gerrit-Project: asterisk
Gerrit-Branch: 11
Gerrit-Owner: Kevin Harwell <kharwell at digium.com>
Gerrit-Reviewer: Joshua Colp <jcolp at digium.com>
Gerrit-Reviewer: Kevin Harwell <kharwell at digium.com>
Gerrit-HasComments: Yes



More information about the asterisk-code-review mailing list