X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=blobdiff_plain;f=compress_filter.c;h=04377b752a89cf83ba33532e4d24542e9d06a064;hp=d0816df44198ae11d1f3b076b262ab16b51e255b;hb=9c5fbc5dd8b53604d7e73fb6714ee2b5e3458866;hpb=b62e2796b85c7d7f3138fe729f4637853e0fafe0 diff --git a/compress_filter.c b/compress_filter.c index d0816df4..04377b75 100644 --- a/compress_filter.c +++ b/compress_filter.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2005-2011 Andre Noll + * Copyright (C) 2005-2013 Andre Noll * * Licensed under the GPL v2. For licencing details see COPYING. */ @@ -11,7 +11,6 @@ */ #include -#include #include "para.h" #include "compress_filter.cmdline.h" @@ -110,24 +109,17 @@ next_buffer: err: assert(ret < 0); t->error = ret; - btr_remove_node(btrn); + btr_remove_node(&fn->btrn); } /** TODO: Add sanity checks */ static int compress_parse_config(int argc, char **argv, void **config) { - int ret; - struct compress_filter_args_info *compress_conf - = para_calloc(sizeof(*compress_conf)); + struct compress_filter_args_info *conf = para_calloc(sizeof(*conf)); - ret = -E_COMPRESS_SYNTAX; - if (compress_cmdline_parser(argc, argv, compress_conf)) - goto err; - *config = compress_conf; + compress_filter_cmdline_parser(argc, argv, conf); + *config = conf; return 1; -err: - free(compress_conf); - return ret; } static void compress_open(struct filter_node *fn) @@ -143,7 +135,7 @@ static void compress_open(struct filter_node *fn) static void compress_free_config(void *conf) { - compress_cmdline_parser_free(conf); + compress_filter_cmdline_parser_free(conf); } /** @@ -155,7 +147,7 @@ void compress_filter_init(struct filter *f) { struct compress_filter_args_info dummy; - compress_cmdline_parser_init(&dummy); + compress_filter_cmdline_parser_init(&dummy); f->open = compress_open; f->close = compress_close; f->pre_select = generic_filter_pre_select;