summaryrefslogtreecommitdiff
path: root/plugins/dca/dcaplug.c
diff options
context:
space:
mode:
authorGravatar Alexey Yakovenko <wakeroid@gmail.com>2010-09-27 21:11:44 +0200
committerGravatar Alexey Yakovenko <wakeroid@gmail.com>2010-09-27 21:11:44 +0200
commit4eee12a1728390feffd020cea12cfa9d3aa0142d (patch)
tree50301ecf4f63910498e99d70812beece51767427 /plugins/dca/dcaplug.c
parent72d4624e6e0d208ccae1541d56875b9b3ac6f9d4 (diff)
fixed heap corruption in dca plugin
Diffstat (limited to 'plugins/dca/dcaplug.c')
-rw-r--r--plugins/dca/dcaplug.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/plugins/dca/dcaplug.c b/plugins/dca/dcaplug.c
index f9be2c29..5c8186b4 100644
--- a/plugins/dca/dcaplug.c
+++ b/plugins/dca/dcaplug.c
@@ -73,7 +73,7 @@ static DB_decoder_t plugin;
DB_functions_t *deadbeef;
#define BUFFER_SIZE 24576
-#define OUT_BUFFER_SIZE 50000
+#define OUT_BUFFER_SIZE 100000 // one block may be up to 22K samples, which is 88Kb for stereo
#define HEADER_SIZE 14
typedef struct {
DB_fileinfo_t info;
@@ -254,6 +254,7 @@ error:
}
}
}
+ trace ("n_decoded: %d (%d bytes)\n", n_decoded, n_decoded * dca_blocks_num (ddb_state->state) * 2);
return n_decoded;
}