Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2021-08-24 15:58:07 +0300
committerAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2021-09-17 05:58:34 +0300
commitfed02825081bd6441f865c9cfcf50e384b2392f5 (patch)
treeb42f4b433b1652e4ad65bc0b5066fe3e80d5662f /libavformat/fsb.c
parentdfbf41775cb58a9218a8b39b0dc6fd8de3f1ab35 (diff)
avformat: Avoid allocation for AVFormatInternal
Do this by allocating AVFormatContext together with the data that is currently in AVFormatInternal; or rather: Put AVFormatContext at the beginning of a new structure called FFFormatContext (which encompasses more than just the internal fields and is a proper context in its own right, hence the name) and remove AVFormatInternal altogether. The biggest simplifications occured in avformat_alloc_context(), where one can now simply call avformat_free_context() in case of errors. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Diffstat (limited to 'libavformat/fsb.c')
-rw-r--r--libavformat/fsb.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/fsb.c b/libavformat/fsb.c
index f145d10fd3..9e8b9ca6b1 100644
--- a/libavformat/fsb.c
+++ b/libavformat/fsb.c
@@ -156,7 +156,7 @@ static int fsb_read_header(AVFormatContext *s)
}
avio_skip(pb, offset - avio_tell(pb));
- s->internal->data_offset = avio_tell(pb);
+ ffformatcontext(s)->data_offset = avio_tell(pb);
avpriv_set_pts_info(st, 64, 1, par->sample_rate);