From 72d9d14c6d70c0b7c14d0dd32925b223f6c7a451 Mon Sep 17 00:00:00 2001 From: Andre Noll Date: Tue, 12 Jan 2010 07:52:02 +0100 Subject: [PATCH] fecdec: Kill some dead code. fn->btrn is never NULL. --- fecdec_filter.c | 22 +++++----------------- 1 file changed, 5 insertions(+), 17 deletions(-) diff --git a/fecdec_filter.c b/fecdec_filter.c index bc0eee92..fd35d5f5 100644 --- a/fecdec_filter.c +++ b/fecdec_filter.c @@ -312,23 +312,11 @@ static int decode_group(struct fecdec_group *fg, struct filter_node *fn) PARA_DEBUG_LOG("writing group %d (%d/%d decoded data bytes)\n", fg->h.group_num, fg->h.group_bytes, fg->h.data_slices_per_group * sb); - if (fn->btrn) { - need = (fg->h.data_slices_per_group - i) * sb; - if (need > btr_pool_unused(pfd->btrp)) - return -E_FECDEC_OVERRUN; - btr_pool_get_buffer(pfd->btrp, &buf); - p = buf; - } else { - need = fn->loaded + (fg->h.data_slices_per_group - i) * sb; - if (need > fn->bufsize) { - fn->bufsize = PARA_MAX(fn->bufsize * 2, need); - if (fn->bufsize > FECDEC_MAX_OUTBUF_SIZE) - return -E_FECDEC_OVERRUN; - PARA_INFO_LOG("increasing fec buf to %zu\n", fn->bufsize); - fn->buf = para_realloc(fn->buf, fn->bufsize); - } - p = fn->buf + fn->loaded; - } + need = (fg->h.data_slices_per_group - i) * sb; + if (need > btr_pool_unused(pfd->btrp)) + return -E_FECDEC_OVERRUN; + btr_pool_get_buffer(pfd->btrp, &buf); + p = buf; if (u == FEC_GROUP_USABLE_WITH_HEADER) { PARA_INFO_LOG("writing audio file header\n"); written = 0; -- 2.39.5