struct btr_node *btrn = fn->btrn;
size_t k, n = frame->header.blocksize;
unsigned channels = FLAC__stream_decoder_get_channels(decoder);
- char *outbuffer = para_malloc(n * channels * 2);
+ char *outbuffer = arr_alloc(n, channels * 2);
if (channels == 1) {
for (k = 0; k < n; k++) {
if (output_queue_full(btrn))
return 0;
ret = btr_node_status(btrn, fn->min_iqs, BTR_NT_INTERNAL);
- if (ret < 0 && ret != -E_BTR_EOF) /* fatal error */
+ if (ret < 0 && ret != -E_EOF) /* fatal error */
goto out;
if (ret <= 0 && !pfd->have_more) /* nothing to do */
goto out;
pfd->have_more = false;
FLAC__stream_decoder_process_single(pfd->decoder);
state = FLAC__stream_decoder_get_state(pfd->decoder);
- ret = -E_FLACDEC_EOF;
+ ret = -E_EOF;
if (state == FLAC__STREAM_DECODER_END_OF_STREAM)
goto out;
if (state == FLAC__STREAM_DECODER_ABORTED) {
static void flacdec_open(struct filter_node *fn)
{
- struct private_flacdec_data *pfd = para_calloc(sizeof(*pfd));
+ struct private_flacdec_data *pfd = zalloc(sizeof(*pfd));
fn->private_data = pfd;
fn->min_iqs = 0;
}