X-Git-Url: http://git.tuebingen.mpg.de/?a=blobdiff_plain;ds=sidebyside;f=oss_write.c;h=33cf8c3cf1d56b3b0e851e1157279e5351529d3f;hb=6df282b25d3ca0f2a55dd09546d0efc42a437ace;hp=0b8f1b5fc976046aeb75056603d231aaf9c4160f;hpb=3642d205180315b8e7c5e46ae18d814d517e0be6;p=paraslash.git diff --git a/oss_write.c b/oss_write.c index 0b8f1b5f..33cf8c3c 100644 --- a/oss_write.c +++ b/oss_write.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2009-2013 Andre Noll + * Copyright (C) 2009-2014 Andre Noll * * Licensed under the GPL v2. For licencing details see COPYING. */ @@ -46,7 +46,7 @@ static int get_oss_format(enum sample_format sf) static void oss_pre_select(struct sched *s, struct task *t) { - struct writer_node *wn = container_of(t, struct writer_node, task); + struct writer_node *wn = task_context(t); struct private_oss_write_data *powd = wn->private_data; int ret = btr_node_status(wn->btrn, wn->min_iqs, BTR_NT_LEAF); @@ -160,7 +160,7 @@ err_free: static int oss_post_select(__a_unused struct sched *s, struct task *t) { - struct writer_node *wn = container_of(t, struct writer_node, task); + struct writer_node *wn = task_context(t); struct private_oss_write_data *powd = wn->private_data; struct btr_node *btrn = wn->btrn; size_t frames, bytes; @@ -232,13 +232,9 @@ void oss_write_init(struct writer *w) oss_write_cmdline_parser_init(&dummy); w->close = oss_close; w->pre_select = oss_pre_select; - w->new_post_select = oss_post_select; - w->post_select = NULL; + w->post_select = oss_post_select; w->parse_config_or_die = oss_parse_config_or_die; w->free_config = oss_free_config; - w->help = (struct ggo_help) { - .short_help = oss_write_args_info_help, - .detailed_help = oss_write_args_info_detailed_help - }; + w->help = (struct ggo_help)DEFINE_GGO_HELP(oss_write); oss_write_cmdline_parser_free(&dummy); }