summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWilliam Wilgus <wilgus.william@gmail.com>2022-05-04 10:25:29 -0400
committerWilliam Wilgus <wilgus.william@gmail.com>2022-05-05 00:31:07 -0400
commit2c4480979f1b0374414b4e49957f1772bd103b79 (patch)
tree48e762475e771768ae5abf11827a7fab6bb1c80a
parent09ef94ed8bd6a7aa0876797a2fa5fd64978aa539 (diff)
downloadrockbox-2c4480979f.tar.gz
rockbox-2c4480979f.zip
tdspeed.c remove buffer name strings
get rid of the magic buffer size and the whole name buffer naming the buffers individually doesn't serve any real purpose instead add a static string for all td buffers Change-Id: I962a966456453e1b84bab6fec6f4df7cb075ef4e
-rw-r--r--apps/rbcodec_helpers.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/apps/rbcodec_helpers.c b/apps/rbcodec_helpers.c
index b412bb3aa4..78e068ded7 100644
--- a/apps/rbcodec_helpers.c
+++ b/apps/rbcodec_helpers.c
@@ -59,18 +59,12 @@ static struct buflib_callbacks ops =
/* Allocate timestretch buffers */
bool tdspeed_alloc_buffers(int32_t **buffers, const int *buf_s, int nbuf)
{
- static const char *buffer_names[4] = {
- "tdspeed ovl L",
- "tdspeed ovl R",
- "tdspeed out L",
- "tdspeed out R"
- };
-
+ /* #Buffer index - 0 ovl L, 1 ovl R, 2 out L, 3 out R */
for (int i = 0; i < nbuf; i++)
{
if (handles[i] <= 0)
{
- handles[i] = core_alloc_ex(buffer_names[i], buf_s[i], &ops);
+ handles[i] = core_alloc_ex("tdspeed", buf_s[i], &ops);
if (handles[i] <= 0)
return false;