fecdec: Kill some dead code.
authorAndre Noll <maan@systemlinux.org>
Tue, 12 Jan 2010 06:52:02 +0000 (07:52 +0100)
committerAndre Noll <maan@systemlinux.org>
Tue, 12 Jan 2010 06:52:02 +0000 (07:52 +0100)
fn->btrn is never NULL.

fecdec_filter.c

index bc0eee9..fd35d5f 100644 (file)
@@ -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;