static void ffm_set_write_index(AVFormatContext *s, int64_t pos,
int64_t file_size)
{
- FFMContext *ffm = s->priv_data;
- ffm->write_index = pos;
- ffm->file_size = file_size;
+ av_opt_set_int(s, "server_attached", 1, AV_OPT_SEARCH_CHILDREN);
+ av_opt_set_int(s, "write_index", pos, AV_OPT_SEARCH_CHILDREN);
+ av_opt_set_int(s, "file_size", file_size, AV_OPT_SEARCH_CHILDREN);
}
static char *ctime1(char *buf2, size_t buf_size)
av_freep(&c->pb_buffer);
len = avio_close_dyn_buf(ctx->pb, &c->pb_buffer);
+ ctx->pb = NULL;
c->cur_frame_bytes = len;
c->buffer_ptr = c->pb_buffer;
c->buffer_end = c->pb_buffer + len;
len = sizeof(line) - 1;
memcpy(line, p, len);
line[len] = '\0';
- ff_rtsp_parse_line(header, line, NULL, NULL);
+ ff_rtsp_parse_line(NULL, header, line, NULL, NULL);
p = p1 + 1;
}
return -1;
}
avio_close_dyn_buf(ctx->pb, &dummy_buf);
+ ctx->pb = NULL;
av_free(dummy_buf);
c->rtp_ctx[stream_index] = ctx;