int len;
if (avio_open_dyn_buf(&s) < 0)
- exit(1);
+ exit_program(1);
p = ost->enc->pix_fmts;
if (ost->st->codec->strict_std_compliance <= FF_COMPLIANCE_UNOFFICIAL) {
int len; \
\
if (avio_open_dyn_buf(&s) < 0) \
- exit(1); \
+ exit_program(1); \
\
for (p = ost->enc->supported_list; *p != none; p++) { \
get_name(*p); \
FilterGraph *fg = av_mallocz(sizeof(*fg));
if (!fg)
- exit(1);
+ exit_program(1);
fg->index = nb_filtergraphs;
GROW_ARRAY(fg->outputs, fg->nb_outputs);
if (!(fg->outputs[0] = av_mallocz(sizeof(*fg->outputs[0]))))
- exit(1);
+ exit_program(1);
fg->outputs[0]->ost = ost;
fg->outputs[0]->graph = fg;
GROW_ARRAY(fg->inputs, fg->nb_inputs);
if (!(fg->inputs[0] = av_mallocz(sizeof(*fg->inputs[0]))))
- exit(1);
+ exit_program(1);
fg->inputs[0]->ist = ist;
fg->inputs[0]->graph = fg;
if (type != AVMEDIA_TYPE_VIDEO && type != AVMEDIA_TYPE_AUDIO) {
av_log(NULL, AV_LOG_FATAL, "Only video and audio filters supported "
"currently.\n");
- exit(1);
+ exit_program(1);
}
if (in->name) {
if (file_idx < 0 || file_idx >= nb_input_files) {
av_log(NULL, AV_LOG_FATAL, "Invalid file index %d in filtergraph description %s.\n",
file_idx, fg->graph_desc);
- exit(1);
+ exit_program(1);
}
s = input_files[file_idx]->ctx;
if (!st) {
av_log(NULL, AV_LOG_FATAL, "Stream specifier '%s' in filtergraph description %s "
"matches no streams.\n", p, fg->graph_desc);
- exit(1);
+ exit_program(1);
}
ist = input_streams[input_files[file_idx]->ist_index + st->index];
} else {
av_log(NULL, AV_LOG_FATAL, "Cannot find a matching stream for "
"unlabeled input pad %d on filter %s\n", in->pad_idx,
in->filter_ctx->name);
- exit(1);
+ exit_program(1);
}
}
av_assert0(ist);
GROW_ARRAY(fg->inputs, fg->nb_inputs);
if (!(fg->inputs[fg->nb_inputs - 1] = av_mallocz(sizeof(*fg->inputs[0]))))
- exit(1);
+ exit_program(1);
fg->inputs[fg->nb_inputs - 1]->ist = ist;
fg->inputs[fg->nb_inputs - 1]->graph = fg;
AVIOContext *pb; \
\
if (avio_open_dyn_buf(&pb) < 0) \
- exit(1); \
+ exit_program(1); \
\
avio_printf(pb, "%s", ctx->filter->name); \
if (nb_pads > 1) \
for (cur = outputs; cur;) {
GROW_ARRAY(fg->outputs, fg->nb_outputs);
if (!(fg->outputs[fg->nb_outputs - 1] = av_mallocz(sizeof(*fg->outputs[0]))))
- exit(1);
+ exit_program(1);
fg->outputs[fg->nb_outputs - 1]->graph = fg;
fg->outputs[fg->nb_outputs - 1]->out_tmp = cur;
cur = cur->next;