It has no more users.
f->close = aacdec_close;
f->pre_select = generic_filter_pre_select;
f->new_post_select = aacdec_post_select;
- f->post_select = NULL;
f->execute = aacdec_execute;
}
r->close = afh_recv_close;
r->pre_select = afh_recv_pre_select;
r->new_post_select = afh_recv_post_select;
- r->post_select = NULL;
r->parse_config = afh_recv_parse_config;
r->free_config = afh_recv_free_config;
r->execute = afh_execute;
st->task.pre_select = signal_pre_select;
st->task.new_post_select = afs_signal_post_select;
- st->task.post_select = NULL;
sprintf(st->task.status, "signal task");
register_task(s, &st->task);
}
ct->task.pre_select = command_pre_select;
ct->task.new_post_select = command_post_select;
- ct->task.post_select = NULL;
sprintf(ct->task.status, "afs command task");
register_task(s, &ct->task);
}
w->close = alsa_close;
w->pre_select = alsa_write_pre_select;
w->new_post_select = alsa_write_post_select;
- w->post_select = NULL;
w->parse_config_or_die = alsa_parse_config_or_die;
w->free_config = alsa_free_config;
w->help = (struct ggo_help) {
f->close = amp_close;
f->pre_select = generic_filter_pre_select;
f->new_post_select = amp_post_select;
- f->post_select = NULL;
f->parse_config = amp_parse_config;
f->free_config = amp_free_config;
f->help = (struct ggo_help) {
w->close = aow_close;
w->pre_select = aow_pre_select;
w->new_post_select = aow_post_select;
- w->post_select = NULL;
w->parse_config_or_die = aow_parse_config_or_die;
w->free_config = aow_free_config;
w->help = (struct ggo_help) {
.task = {
.pre_select = audioc_pre_select,
.new_post_select = audioc_post_select,
- .post_select = NULL,
.status = "audioc task"
},
}, *at = &audioc_task;
fn->filter_num = a->filter_nums[i];
fn->conf = a->filter_conf[i];
fn->task.pre_select = f->pre_select;
- if (f->new_post_select) {
- fn->task.new_post_select = f->new_post_select;
- fn->task.post_select = NULL;
- } else {
- fn->task.new_post_select = NULL;
- fn->task.post_select = f->post_select;
- }
+ fn->task.new_post_select = f->new_post_select;
fn->btrn = btr_new_node(&(struct btr_node_description)
EMBRACE(.name = f->name, .parent = parent,
.handler = f->execute, .context = fn));
PARA_NOTICE_LOG("started %s: %s receiver in slot %d\n",
audio_formats[format], r->name, slot_num);
rn->task.pre_select = r->pre_select;
- if (r->new_post_select) {
- rn->task.new_post_select = r->new_post_select;
- rn->task.post_select = NULL;
- } else {
- rn->task.new_post_select = NULL;
- rn->task.post_select = r->post_select;
- }
+ rn->task.new_post_select = r->new_post_select;
sprintf(rn->task.status, "%s receiver node", r->name);
register_task(&sched, &rn->task);
return slot_num;
{
st->task.pre_select = signal_pre_select;
st->task.new_post_select = signal_post_select;
- st->task.post_select = NULL;
sprintf(st->task.status, "signal task");
}
{
ct->task.pre_select = command_pre_select;
ct->task.new_post_select = command_post_select;
- ct->task.post_select = NULL;
ct->task.error = 0;
ct->fd = audiod_get_socket(); /* doesn't return on errors */
sprintf(ct->task.status, "command task");
memset(st, 0, sizeof(struct status_task));
st->task.pre_select = status_pre_select;
st->task.new_post_select = status_post_select;
- st->task.post_select = NULL;
st->sa_time_diff_sign = 1;
st->clock_diff_count = conf.clock_diff_count_arg;
st->current_audio_format_num = -1;
.task = {
.pre_select = exec_pre_select,
.new_post_select = exec_post_select,
- .post_select = NULL,
.status = "client exec task",
},
.result_buf = para_strdup(""),
static struct task svt = {
.new_post_select = supervisor_post_select,
- .post_select = NULL,
.status = "supervisor task"
};
EMBRACE(.name = "client", .parent = parent, .child = child));
ct->task.pre_select = client_pre_select;
ct->task.new_post_select = client_post_select;
- ct->task.post_select = NULL;
ct->task.error = 0;
sprintf(ct->task.status, "client");
register_task(s, &ct->task);
f->close = compress_close;
f->pre_select = generic_filter_pre_select;
f->new_post_select = compress_post_select;
- f->post_select = NULL;
f->parse_config = compress_parse_config;
f->free_config = compress_free_config;
f->help = (struct ggo_help) {
r->open = dccp_recv_open;
r->close = dccp_recv_close;
r->pre_select = dccp_recv_pre_select;
- r->post_select = NULL;
r->new_post_select = dccp_recv_post_select;
r->parse_config = dccp_recv_parse_config;
r->free_config = dccp_recv_free_config;
f->open = fecdec_open;
f->pre_select = generic_filter_pre_select;
f->new_post_select = fecdec_post_select;
- f->post_select = NULL;
}
file_write_cmdline_parser_init(&dummy);
w->pre_select = file_write_pre_select;
w->new_post_select = file_write_post_select;
- w->post_select = NULL;
w->parse_config_or_die = file_write_parse_config_or_die;
w->free_config = file_write_free_config;
w->close = file_write_close;
EMBRACE(.name = f->name, .parent = parent,
.handler = f->execute, .context = fn));
fn->task.pre_select = f->pre_select;
- if (f->new_post_select) {
- fn->task.new_post_select = f->new_post_select;
- fn->task.post_select = NULL;
- } else {
- fn->task.new_post_select = NULL;
- fn->task.post_select = f->post_select;
- }
+ fn->task.new_post_select = f->new_post_select;
f->open(fn);
register_task(&s, &fn->task);
parent = fn->btrn;
* post_select function is supposed to set t->error to a (negative)
* error code.
*/
- void (*post_select)(struct sched *s, struct task *t);
- /** New variant, see sched.h. */
int (*new_post_select)(struct sched *s, struct task *t);
/**
* Answer a buffer tree query.
f->close = flacdec_close;
f->pre_select = flacdec_pre_select;
f->new_post_select = flacdec_post_select;
- f->post_select = NULL;
f->execute = flacdec_execute;
}
EMBRACE(.name = name, .parent = parent));
gc->task.pre_select = gc_pre_select;
gc->task.new_post_select = gc_post_select;
- gc->task.post_select = NULL;
snprintf(gc->task.status, sizeof(gc->task.status) - 1, "%s", name);
gc->task.status[sizeof(gc->task.status) - 1] = '\0';
gc->task.error = 0;
r->open = http_recv_open;
r->close = http_recv_close;
r->pre_select = http_recv_pre_select;
- r->post_select = NULL;
r->new_post_select = http_recv_post_select;
r->parse_config = http_recv_parse_config;
r->free_config = http_recv_free_config;
return ret;
i9ep->task.pre_select = i9e_pre_select;
i9ep->task.new_post_select = i9e_post_select;
- i9ep->task.post_select = NULL;
sprintf(i9ep->task.status, "i9e");
register_task(s, &i9ep->task);
rl_readline_name = "para_i9e";
f->free_config = mp3dec_free_config;
f->pre_select = generic_filter_pre_select;
f->new_post_select = mp3dec_post_select;
- f->post_select = NULL;
f->execute = mp3dec_execute;
f->help = (struct ggo_help) {
.short_help = mp3dec_filter_args_info_help,
f->close = ogg_close;
f->pre_select = ogg_pre_select;
f->new_post_select = ogg_post_select;
- f->post_select = NULL;
f->execute = oggdec_execute;
}
w->close = oss_close;
w->pre_select = oss_pre_select;
w->new_post_select = oss_post_select;
- w->post_select = NULL;
w->parse_config_or_die = oss_parse_config_or_die;
w->free_config = oss_free_config;
w->help = (struct ggo_help) {
w->close = osx_write_close;
w->pre_select = osx_write_pre_select;
w->new_post_select = osx_write_post_select;
- w->post_select = NULL;
w->parse_config_or_die = osx_write_parse_config_or_die;
w->free_config = osx_free_config;
w->help = (struct ggo_help) {
tmp = NULL;
}
pt->rn.task.pre_select = afh_recv->pre_select;
- if (afh_recv->new_post_select) {
- pt->rn.task.new_post_select = afh_recv->new_post_select;
- pt->rn.task.post_select = NULL;
- } else {
- pt->rn.task.post_select = NULL;
- pt->rn.task.new_post_select = afh_recv->new_post_select;
- }
+ pt->rn.task.new_post_select = afh_recv->new_post_select;
sprintf(pt->rn.task.status, "%s receiver node", afh_recv->name);
return 1;
fail:
pt->fn.filter_num = ret;
decoder = filters + ret;
pt->fn.task.pre_select = decoder->pre_select;
- if (decoder->new_post_select) {
- pt->fn.task.new_post_select = decoder->new_post_select;
- pt->fn.task.post_select = NULL;
- } else {
- pt->fn.task.new_post_select = NULL;
- pt->fn.task.post_select = decoder->post_select;
- }
+ pt->fn.task.new_post_select = decoder->new_post_select;
sprintf(pt->fn.task.status, "%s decoder", af);
pt->fn.btrn = btr_new_node(&(struct btr_node_description)
EMBRACE(.name = decoder->name, .parent = pt->rn.btrn,
pt->playing = true;
pt->task.pre_select = play_pre_select;
pt->task.new_post_select = play_post_select;
- pt->task.post_select = NULL;
sprintf(pt->task.status, "play task");
register_task(&sched, &pt->task);
ret = schedule(&sched);
f->free_config = prebuffer_free_config;
f->pre_select = prebuffer_pre_select;
f->new_post_select = prebuffer_post_select;
- f->post_select = NULL;
f->help = (struct ggo_help) {
.short_help = prebuffer_filter_args_info_help,
.detailed_help = prebuffer_filter_args_info_detailed_help
register_task(&s, &sot.task);
rn.task.pre_select = r->pre_select;
- if (r->new_post_select) {
- rn.task.new_post_select = r->new_post_select;
- rn.task.post_select = NULL;
- } else {
- rn.task.new_post_select = NULL;
- rn.task.post_select = r->post_select;;
- }
+ rn.task.new_post_select = r->new_post_select;
sprintf(rn.task.status, "%s", r->name);
register_task(&s, &rn.task);
*
* \sa select(2), struct receiver.
*/
- void (*post_select)(struct sched *s, struct task *t);
- /** New variant, see sched.h. */
int (*new_post_select)(struct sched *s, struct task *t);
/** The two help texts of this receiver. */
f->open = resample_open;
f->pre_select = resample_pre_select;
f->new_post_select = resample_post_select;
- f->post_select = NULL;
f->parse_config = resample_parse_config;
f->free_config = resample_free_config;
f->execute = resample_execute;
para_strerror(-t->error));
if (t->pre_select)
list_del(&t->pre_select_node);
- if (t->new_post_select || t->post_select)
+ if (t->new_post_select)
list_del(&t->post_select_node);
}
static inline void call_post_select(struct sched *s, struct task *t)
{
#ifndef SCHED_DEBUG
- if (t->new_post_select) {
- t->error = t->new_post_select(s, t);
- return;
- }
- return t->post_select(s, t);
+ t->error = t->new_post_select(s, t);
#else
struct timeval t1, t2, diff;
unsigned long pst;
clock_get_realtime(&t1);
- if (t->new_post_select)
- t->error = t->new_post_select(s, t);
- else
- t->post_select(s, t);
+ t->error = t->new_post_select(s, t);
clock_get_realtime(&t2);
tv_diff(&t1, &t2, &diff);
pst = tv2ms(&diff);
if (t->new_post_select) {
PARA_DEBUG_LOG("post_select: %p\n", &t->new_post_select);
list_add_tail(&t->post_select_node, &s->post_select_list);
- } else if ((t->post_select)) {
- PARA_DEBUG_LOG("post_select: %p\n", &t->post_select);
- list_add_tail(&t->post_select_node, &s->post_select_list);
}
}
* scheduler and to decrease the select timeout if necessary.
*/
void (*pre_select)(struct sched *s, struct task *t);
- /**
- * The postselect hook of \a t.
- *
- * Evaluate and act upon the results of the previous select call.
- */
- void (*post_select)(struct sched *s, struct task *t);
/**
* The newer variant of the post select hook of \a t.
*
st->task.pre_select = signal_pre_select;
st->task.new_post_select = signal_post_select;
- st->task.post_select = NULL;
sprintf(st->task.status, "signal task");
PARA_NOTICE_LOG("setting up signal handling\n");
PARA_NOTICE_LOG("initializing tcp command socket\n");
sct->task.pre_select = command_pre_select;
sct->task.new_post_select = command_post_select;
- sct->task.post_select = NULL;
sct->argc = argc;
sct->argv = argv;
ret = para_listen_simple(IPPROTO_TCP, conf.port_arg);
f->close = speexdec_close;
f->pre_select = generic_filter_pre_select;
f->new_post_select = speexdec_post_select;
- f->post_select = NULL;
f->execute = speexdec_execute;
}
sit->task.pre_select = stdin_pre_select;
sit->task.new_post_select = stdin_post_select;
- sit->task.post_select = NULL;
sit->btrp = btr_pool_new("stdin", 128 * 1024);
sprintf(sit->task.status, "stdin reader");
ret = mark_fd_nonblocking(STDIN_FILENO);
sot->task.pre_select = stdout_pre_select;
sot->task.new_post_select = stdout_post_select;
- sot->task.post_select = NULL;
sprintf(sot->task.status, "stdout");
ret = mark_fd_nonblocking(STDOUT_FILENO);
if (ret >= 0)
r->open = udp_recv_open;
r->close = udp_recv_close;
r->pre_select = udp_recv_pre_select;
- r->post_select = NULL;
r->new_post_select = udp_recv_post_select;
r->parse_config = udp_recv_parse_config;
r->free_config = udp_recv_free_config;
vsst->afs_socket = afs_socket;
vsst->task.pre_select = vss_pre_select;
vsst->task.new_post_select = vss_post_select;
- vsst->task.post_select = NULL;
ms2tv(announce_time, &vsst->announce_tv);
PARA_INFO_LOG("announce timeval: %lums\n", tv2ms(&vsst->announce_tv));
INIT_LIST_HEAD(&fec_client_list);
f->open = wav_open;
f->pre_select = wav_pre_select;
f->new_post_select = wav_post_select;
- f->post_select = NULL;
}
f->execute = wmadec_execute;
f->pre_select = generic_filter_pre_select;
f->new_post_select = wmadec_post_select;
- f->post_select = NULL;
}
*
* Called from the post_select function of the writer node's task.
*/
- void (*post_select)(struct sched *s, struct task *t);
- /** New variant, see sched.h. */
int (*new_post_select)(struct sched *s, struct task *t);
/**
* Close one instance of the writer.
strcpy(wn->task.status, name);
free(name);
wn->task.pre_select = w->pre_select;
- if (w->new_post_select) {
- wn->task.new_post_select = w->new_post_select;
- wn->task.post_select = NULL;
- } else {
- wn->task.new_post_select = NULL;
- wn->task.post_select = w->post_select;
- }
+ wn->task.new_post_select = w->new_post_select;
register_task(s, &wn->task);
}