heif_items are reused and to avoid leaking memory or using stale name,
clear it first.
Fixes: 432505829/clusterfuzz-testcase-minimized-ffmpeg_dem_MOV_fuzzer-6654363487764480
Found-by: OSS-Fuzz
Signed-off-by: Kacper Michajłow <kasper93@gmail.com>
The SRTP profile string "SRTP_AES128_CM_SHA1_80" is only used when
use_srtp is enabled. Move its declaration inside the "if (s->use_srtp)"
block to limit scope
Signed-off-by: Jack Lau <jacklau1222@qq.com>
Pure cleanup, no functional changes
Unify local pointer names to `TLSContext *c` and `TLSShared *s` to
reduce confusion from inconsistent names (e.g. p, ctx, s, c)
Signed-off-by: Jack Lau <jacklau1222@qq.com>
Simple parser that only parses frame information.
This helps avoid requiring the software decoder on init to decode a
single frame, since the decoder can be quite slow.
Fixes: utils.c:524:9: runtime error: call to function
handle_init_section_args through pointer to incorrect function type
'void (*)(void *, const char *, int, char **, int *)'
Signed-off-by: Kacper Michajłow <kasper93@gmail.com>
In general, a provider code corresponds to a company/organization, and
the name should be that of the company, not of a given feature.
The feature is signalled in the "provider oriented code".
The exception is HDR Vivid, where the code 0x0004 indicates the HDR Vivid
feature itself rather than CUVA (China UHD Video Industry Alliance),
according to the UHD World Associations 'HDR Video Technology Part 2-1
Application Guide to System Integration' document.
ITU_T_T35_PROVIDER_CODE_CUVA -> ITU_T_T35_PROVIDER_CODE_HDR_VIVID
ITU_T_T35_PROVIDER_CODE_LCEVC-> ITU_T_T35_PROVIDER_CODE_VNOVA
ITU_T_T35_PROVIDER_CODE_SMTPE -> ITU_T_T35_PROVIDER_CODE_SAMSUNG
Signed-off-by: Maryla Ustarroz-Calonge <maryla@google.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Introduced by 307983b292
Use the following command line to reproduce the issue:
./configure --toolchain=msvc --disable-asm --enable-ffmpeg \
--disable-everything --enable-decoder=vvc --enable-parser=vvc \
--enable-demuxer='vvc,mpegts' --enable-protocol='file,pipe' \
--enable-encoder='rawvideo,wrapped_avframe' \
--enable-muxer='rawvideo,md5,null'
Signed-off-by: Wu Jianhua <toqsxw@outlook.com>
The check to return on EOF should not be inside a block that will not be entered after reaching EOF.
Should fix "libavcodec/bytestream.h:144:27: runtime error: applying zero offset to null pointer".
Signed-off-by: James Almer <jamrial@gmail.com>
- proper pts for packets. leaving it blank leaves it up for guessing,
but the guess doesn't take seeking into account, causing weirdness.
- clamp to 0 when seeking to negative ts. libopenmpt docs are unclear on
this but not doing this causes an immediate EOF when seeking backwards
to the beginning in mpv.
- only set song duration and packet pts when they are non-negative and
in int64 range. NaNs count as out of range. this isn't a fix for any
specific issue but might be helpful still, and shouldn't break
anything.
Allows to output LRC with more precision than standard centiseconds.
Time base is determined by number of requested digits.
Signed-off-by: Kacper Michajłow <kasper93@gmail.com>
Apparently files with milliseconds exist in the wild. And since it cost
nothing to support arbitrary number of digits, extend format to support
that.
Depending on number of digits, the time base of fractional part is
changing. Most LRCs use 2 digits and centiseconds base, but subs with 3
digits and miliseconds exist too.
Set internal time base to AV_TIME_BASE, which in parcitice allows to
hold microseconds with 6 digits. Totally artificial, but who knows maybe
someone wants that.
Fixes: #11677
Signed-off-by: Kacper Michajłow <kasper93@gmail.com>
This will ensure it will be stored in the stream's private context, so it can
be fetched and replaced as required.
Fixes a regression since eefa6de7d5.
Fixes avc-intra-panasonic-AG-HPX301E.mov
Signed-off-by: James Almer <jamrial@gmail.com>
Fixes: writing 1 byte over the end of the array
Fixes: BIGSLEEP-433502298/test.xml
Found-by: Google Big Sleep
A prettier solution is welcome!
A testcase exists only for the baseurl case
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Fixes issue #20018.
Note that Codec Descriptors are not written for all these ai** codec tags, and no
considerations were ever made to ensure parameter sets are present in muxed packets.
Their usage may result in unplayable files if parameter sets are only available
in extradata (Default behavior for x264 encoding when combined with this muxer).
Signed-off-by: James Almer <jamrial@gmail.com>
That occurs when H261, H263, and MPEG4 decoders are disabled.
Signed-off-by: zhaozhenghang <15083277223@163.com>
Signed-off-by: Zhao Zhili <zhilizhao@tencent.com>
If a packet contains new extradata within a side data entry, save for
specific cases it means the coded stream changed. If ignored, upon
demuxing every packet from then onwards may be undecodable.
Signed-off-by: James Almer <jamrial@gmail.com>
The first sample in the stsc box may not refer to the first stsd entry.
This is the case in h264/thezerotheorem-cut.mp4, and as such the
fate-h264_redundant_pps-side_data test is updated accordingly.
Signed-off-by: James Almer <jamrial@gmail.com>