[FFmpeg-cvslog] avfilter/vf_fade: fix start/duration max value
ffmpeg | branch: master | Mark Harris | Sun Nov 11 22:54:04 2018 -0800| [ae4323548ae821db81b73bc66cf5a2f9885296cb] | committer: Paul B Mahol avfilter/vf_fade: fix start/duration max value A fade out (usually at the end of a video) can easily start beyond INT32_MAX (about 36 minutes). Regression since d40dc64173. > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=ae4323548ae821db81b73bc66cf5a2f9885296cb --- libavfilter/vf_fade.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/libavfilter/vf_fade.c b/libavfilter/vf_fade.c index c30c41db0d..17eca109b6 100644 --- a/libavfilter/vf_fade.c +++ b/libavfilter/vf_fade.c @@ -386,13 +386,13 @@ static const AVOption fade_options[] = { OFFSET(nb_frames), AV_OPT_TYPE_INT, { .i64 = 25 }, 0, INT_MAX, FLAGS }, { "alpha", "fade alpha if it is available on the input", OFFSET(alpha), AV_OPT_TYPE_BOOL, {.i64 = 0}, 0, 1, FLAGS }, { "start_time", "Number of seconds of the beginning of the effect.", -OFFSET(start_time), AV_OPT_TYPE_DURATION, {.i64 = 0. }, 0, INT32_MAX, FLAGS }, +OFFSET(start_time), AV_OPT_TYPE_DURATION, {.i64 = 0. }, 0, INT64_MAX, FLAGS }, { "st", "Number of seconds of the beginning of the effect.", -OFFSET(start_time), AV_OPT_TYPE_DURATION, {.i64 = 0. }, 0, INT32_MAX, FLAGS }, +OFFSET(start_time), AV_OPT_TYPE_DURATION, {.i64 = 0. }, 0, INT64_MAX, FLAGS }, { "duration","Duration of the effect in seconds.", -OFFSET(duration), AV_OPT_TYPE_DURATION, {.i64 = 0. }, 0, INT32_MAX, FLAGS }, +OFFSET(duration), AV_OPT_TYPE_DURATION, {.i64 = 0. }, 0, INT64_MAX, FLAGS }, { "d", "Duration of the effect in seconds.", -OFFSET(duration), AV_OPT_TYPE_DURATION, {.i64 = 0. }, 0, INT32_MAX, FLAGS }, +OFFSET(duration), AV_OPT_TYPE_DURATION, {.i64 = 0. }, 0, INT64_MAX, FLAGS }, { "color", "set color", OFFSET(color_rgba), AV_OPT_TYPE_COLOR,{.str = "black"}, CHAR_MIN, CHAR_MAX, FLAGS }, { "c", "set color", OFFSET(color_rgba), AV_OPT_TYPE_COLOR,{.str = "black"}, CHAR_MIN, CHAR_MAX, FLAGS }, { NULL } ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avfilter/vf_fade: fix start/duration max value
ffmpeg | branch: release/4.1 | Mark Harris | Sun Nov 11 22:54:04 2018 -0800| [fed94c2f22fc165e1b012e3b621802b4d03e9214] | committer: Marton Balint avfilter/vf_fade: fix start/duration max value A fade out (usually at the end of a video) can easily start beyond INT32_MAX (about 36 minutes). Regression since d40dc64173. (cherry picked from commit ae4323548ae821db81b73bc66cf5a2f9885296cb) > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=fed94c2f22fc165e1b012e3b621802b4d03e9214 --- libavfilter/vf_fade.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/libavfilter/vf_fade.c b/libavfilter/vf_fade.c index c30c41db0d..17eca109b6 100644 --- a/libavfilter/vf_fade.c +++ b/libavfilter/vf_fade.c @@ -386,13 +386,13 @@ static const AVOption fade_options[] = { OFFSET(nb_frames), AV_OPT_TYPE_INT, { .i64 = 25 }, 0, INT_MAX, FLAGS }, { "alpha", "fade alpha if it is available on the input", OFFSET(alpha), AV_OPT_TYPE_BOOL, {.i64 = 0}, 0, 1, FLAGS }, { "start_time", "Number of seconds of the beginning of the effect.", -OFFSET(start_time), AV_OPT_TYPE_DURATION, {.i64 = 0. }, 0, INT32_MAX, FLAGS }, +OFFSET(start_time), AV_OPT_TYPE_DURATION, {.i64 = 0. }, 0, INT64_MAX, FLAGS }, { "st", "Number of seconds of the beginning of the effect.", -OFFSET(start_time), AV_OPT_TYPE_DURATION, {.i64 = 0. }, 0, INT32_MAX, FLAGS }, +OFFSET(start_time), AV_OPT_TYPE_DURATION, {.i64 = 0. }, 0, INT64_MAX, FLAGS }, { "duration","Duration of the effect in seconds.", -OFFSET(duration), AV_OPT_TYPE_DURATION, {.i64 = 0. }, 0, INT32_MAX, FLAGS }, +OFFSET(duration), AV_OPT_TYPE_DURATION, {.i64 = 0. }, 0, INT64_MAX, FLAGS }, { "d", "Duration of the effect in seconds.", -OFFSET(duration), AV_OPT_TYPE_DURATION, {.i64 = 0. }, 0, INT32_MAX, FLAGS }, +OFFSET(duration), AV_OPT_TYPE_DURATION, {.i64 = 0. }, 0, INT64_MAX, FLAGS }, { "color", "set color", OFFSET(color_rgba), AV_OPT_TYPE_COLOR,{.str = "black"}, CHAR_MIN, CHAR_MAX, FLAGS }, { "c", "set color", OFFSET(color_rgba), AV_OPT_TYPE_COLOR,{.str = "black"}, CHAR_MIN, CHAR_MAX, FLAGS }, { NULL } ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avformat/icodec: Fix crash probing fuzzed file
ffmpeg | branch: release/3.0 | Mark Harris | Mon Feb 15 23:52:13 2016 -0800| [9375a7d85e8bc78dbb5cc101c37ff7c51f7d9b24] | committer: Andreas Cadhalpun avformat/icodec: Fix crash probing fuzzed file Avoid invalid memory read/crash when frame offset >= 0xfff8. Base64-encoded example: AAABADAwMDAwMAAAMAAwMDAw/P///w== (The previous commit verifies that p->buf_size >= 22.) Signed-off-by: Michael Niedermayer (cherry picked from commit 56e2cd9c042e05255aa28487694c29aaec023263) Signed-off-by: Andreas Cadhalpun > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=9375a7d85e8bc78dbb5cc101c37ff7c51f7d9b24 --- libavformat/icodec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/icodec.c b/libavformat/icodec.c index 20721d5..bd83ef4 100644 --- a/libavformat/icodec.c +++ b/libavformat/icodec.c @@ -60,7 +60,7 @@ static int probe(AVProbeData *p) offset = AV_RL32(p->buf + 18 + i * 16); if (offset < 22) return FFMIN(i, AVPROBE_SCORE_MAX / 4); -if (offset + 8 > p->buf_size) +if (offset > p->buf_size - 8) return AVPROBE_SCORE_MAX / 4 + FFMIN(i, 1); if (p->buf[offset] != 40 && AV_RB64(p->buf + offset) != PNGSIG) return FFMIN(i, AVPROBE_SCORE_MAX / 4); ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avformat/wavdec: Eliminate goto for clang -O0 DCE
ffmpeg | branch: master | Mark Harris | Thu Dec 15 16:44:57 2016 -0800| [a5cf600ccb7f20b65d552fef5c5d010513fcf74c] | committer: Michael Niedermayer avformat/wavdec: Eliminate goto for clang -O0 DCE Clang is not able to eliminate the reference to ff_spdif_probe() when there is a goto target in the same block and optimization is disabled. This fixes the following build failure on OS X: ./configure --disable-everything --disable-doc \ --enable-decoder=pcm_s16le --enable-demuxer=wav \ --enable-protocol=file --disable-optimizations --cc=clang make ... Undefined symbols for architecture x86_64: "_ff_spdif_probe", referenced from: _set_spdif in libavformat.a(wavdec.o) ld: symbol(s) not found for architecture x86_64 Signed-off-by: Michael Niedermayer > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=a5cf600ccb7f20b65d552fef5c5d010513fcf74c --- libavformat/wavdec.c | 38 +- 1 file changed, 17 insertions(+), 21 deletions(-) diff --git a/libavformat/wavdec.c b/libavformat/wavdec.c index 7176cd6..ae42a61 100644 --- a/libavformat/wavdec.c +++ b/libavformat/wavdec.c @@ -64,34 +64,30 @@ static void set_spdif(AVFormatContext *s, WAVDemuxContext *wav) { if (CONFIG_SPDIF_DEMUXER && s->streams[0]->codecpar->codec_tag == 1) { enum AVCodecID codec; -uint8_t *buf = NULL; int len = 1<<16; int ret = ffio_ensure_seekback(s->pb, len); -int64_t pos = avio_tell(s->pb); -if (ret < 0) -goto end; - -buf = av_malloc(len); -if (!buf) { -ret = AVERROR(ENOMEM); -goto end; +if (ret >= 0) { +uint8_t *buf = av_malloc(len); +if (!buf) { +ret = AVERROR(ENOMEM); +} else { +int64_t pos = avio_tell(s->pb); +len = ret = avio_read(s->pb, buf, len); +if (len >= 0) { +ret = ff_spdif_probe(buf, len, &codec); +if (ret > AVPROBE_SCORE_EXTENSION) { +s->streams[0]->codecpar->codec_id = codec; +wav->spdif = 1; +} +} +avio_seek(s->pb, pos, SEEK_SET); +av_free(buf); +} } -len = ret = avio_read(s->pb, buf, len); -if (ret < 0) -goto end; - -ret = ff_spdif_probe(buf, len, &codec); -if (ret > AVPROBE_SCORE_EXTENSION) { -s->streams[0]->codecpar->codec_id = codec; -wav->spdif = 1; -} -end: -avio_seek(s->pb, pos, SEEK_SET); if (ret < 0) av_log(s, AV_LOG_WARNING, "Cannot check for SPDIF\n"); -av_free(buf); } } ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avcodec: Use get_ue_golomb_long() when needed
ffmpeg | branch: master | Mark Harris | Mon Dec 28 23:04:08 2015 -0800| [c51c08e0e70c186971385bdbb225f69edd4e3375] | committer: Michael Niedermayer avcodec: Use get_ue_golomb_long() when needed get_ue_golomb() cannot decode values larger than 8190 (the maximum value that can be golomb encoded in 25 bits) and produces the error "Invalid UE golomb code" if a larger value is encountered. Use get_ue_golomb_long() instead (which supports 63 bits, up to 4294967294) when valid h264/hevc values can exceed 8190. This updates decoding of the following values: (maximum) first_mb_in_slice36863* for level 5.2 abs_diff_pic_num_minus1 131071 difference_of_pic_nums_minus1 131071 idr_pic_id 65535 recovery_frame_cnt 65535 frame_packing_arrangement_id4294967294 frame_packing_arrangement_repetition_period 16384 display_orientation_repetition_period16384 An alternative would be to modify get_ue_golomb() to handle encoded values of up to 49 bits as was done for get_se_golomb() in a92816c. In that case get_ue_golomb() could continue to be used for all of these except frame_packing_arrangement_id. Signed-off-by: Michael Niedermayer > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=c51c08e0e70c186971385bdbb225f69edd4e3375 --- libavcodec/golomb.h |2 +- libavcodec/h264.c|2 +- libavcodec/h264_parser.c |6 +++--- libavcodec/h264_refs.c |4 ++-- libavcodec/h264_sei.c| 10 +- libavcodec/h264_slice.c |2 +- libavcodec/hevc_sei.c|2 +- 7 files changed, 14 insertions(+), 14 deletions(-) diff --git a/libavcodec/golomb.h b/libavcodec/golomb.h index 5136a04..d4df0b3 100644 --- a/libavcodec/golomb.h +++ b/libavcodec/golomb.h @@ -48,7 +48,7 @@ extern const int8_t ff_interleaved_se_golomb_vlc_code[256]; extern const uint8_t ff_interleaved_dirac_golomb_vlc_code[256]; /** - * read unsigned exp golomb code. + * Read an unsigned Exp-Golomb code in the range 0 to 8190. */ static inline int get_ue_golomb(GetBitContext *gb) { diff --git a/libavcodec/h264.c b/libavcodec/h264.c index 089a86f..139011b 100644 --- a/libavcodec/h264.c +++ b/libavcodec/h264.c @@ -1365,7 +1365,7 @@ static int get_last_needed_nal(H264Context *h, const uint8_t *buf, int buf_size) case NAL_IDR_SLICE: case NAL_SLICE: init_get_bits(&gb, ptr, bit_length); -if (!get_ue_golomb(&gb) || +if (!get_ue_golomb_long(&gb) || // first_mb_in_slice !first_slice || first_slice != h->nal_unit_type) nals_needed = nal_index; diff --git a/libavcodec/h264_parser.c b/libavcodec/h264_parser.c index 19d1aa3..12d6397 100644 --- a/libavcodec/h264_parser.c +++ b/libavcodec/h264_parser.c @@ -152,7 +152,7 @@ static int scan_mmco_reset(AVCodecParserContext *s) unsigned int reordering_of_pic_nums_idc = get_ue_golomb_31(&sl->gb); if (reordering_of_pic_nums_idc < 3) -get_ue_golomb(&sl->gb); +get_ue_golomb_long(&sl->gb); else if (reordering_of_pic_nums_idc > 3) { av_log(h->avctx, AV_LOG_ERROR, "illegal reordering_of_pic_nums_idc %d\n", @@ -191,7 +191,7 @@ static int scan_mmco_reset(AVCodecParserContext *s) return 1; if (opcode == MMCO_SHORT2UNUSED || opcode == MMCO_SHORT2LONG) -get_ue_golomb(&sl->gb); +get_ue_golomb_long(&sl->gb); // difference_of_pic_nums_minus1 if (opcode == MMCO_SHORT2LONG || opcode == MMCO_LONG2UNUSED || opcode == MMCO_LONG || opcode == MMCO_SET_MAX_LONG) get_ue_golomb_31(&sl->gb); @@ -373,7 +373,7 @@ static inline int parse_nal_units(AVCodecParserContext *s, } if (h->nal_unit_type == NAL_IDR_SLICE) -get_ue_golomb(&sl->gb); /* idr_pic_id */ +get_ue_golomb_long(&sl->gb); /* idr_pic_id */ if (h->sps.poc_type == 0) { h->poc_lsb = get_bits(&sl->gb, h->sps.log2_max_poc_lsb); diff --git a/libavcodec/h264_refs.c b/libavcodec/h264_refs.c index fbdcbd6..52fedc1 100644 --- a/libavcodec/h264_refs.c +++ b/libavcodec/h264_refs.c @@ -266,7 +266,7 @@ int ff_h264_decode_ref_pic_list_reordering(H264Context *h, H264SliceContext *sl) switch (modification_of_pic_nums_idc) { case 0: case 1: { -const unsigned int abs_diff_pic_num = get_ue_golomb(&sl->gb) + 1; +const unsigned int abs_diff_pic_num = get_ue_golomb_long(&sl-
[FFmpeg-cvslog] doc/filters.texi: fix filter name in examples
ffmpeg | branch: master | Mark Harris | Mon Sep 1 12:32:33 2014 -0700| [1b3a98f137900b6c3eb9a4c177d0b25684d6d144] | committer: Michael Niedermayer doc/filters.texi: fix filter name in examples Signed-off-by: Michael Niedermayer > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=1b3a98f137900b6c3eb9a4c177d0b25684d6d144 --- doc/filters.texi |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/filters.texi b/doc/filters.texi index cca15fc..4ae5b4f 100644 --- a/doc/filters.texi +++ b/doc/filters.texi @@ -491,7 +491,7 @@ aeval=val(ch)/2:c=same @item Invert phase of the second channel: @example -eval=val(0)|-val(1) +aeval=val(0)|-val(1) @end example @end itemize @@ -9492,7 +9492,7 @@ Default value is "all", which will cycle through the list of all tests. Some examples: @example -testsrc=t=dc_luma +mptestsrc=t=dc_luma @end example will generate a "dc_luma" test pattern. ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] tools/normalize.py: both input and output file names are required
ffmpeg | branch: master | Mark Harris | Mon Sep 1 15:13:42 2014 -0700| [4cabee50f624de9b9bb074d8571abb0f06e0b635] | committer: Clément Bœsch tools/normalize.py: both input and output file names are required > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=4cabee50f624de9b9bb074d8571abb0f06e0b635 --- tools/normalize.py |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/normalize.py b/tools/normalize.py index e015913..7d87c5e 100755 --- a/tools/normalize.py +++ b/tools/normalize.py @@ -2,7 +2,7 @@ import sys, subprocess -if len(sys.argv) > 1: +if len(sys.argv) > 2: ifile = sys.argv[1] encopt = sys.argv[2:-1] ofile = sys.argv[-1] ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] doc/filters.texi: fix time duration references
ffmpeg | branch: master | Mark Harris | Thu Sep 4 13:19:44 2014 -0700| [ef16d1260617cb942b495e322a9668c4b93265e0] | committer: Stefano Sabatini doc/filters.texi: fix time duration references Make time duration references consistent, using @ref links, and eliminate incorrect syntax [-]HH[:MM[:SS[.m...]]]. Signed-off-by: Stefano Sabatini > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=ef16d1260617cb942b495e322a9668c4b93265e0 --- doc/filters.texi | 68 +++--- 1 file changed, 29 insertions(+), 39 deletions(-) diff --git a/doc/filters.texi b/doc/filters.texi index 4ae5b4f..d13278e 100644 --- a/doc/filters.texi +++ b/doc/filters.texi @@ -517,27 +517,21 @@ volume as the input audio, at the end of the fade-out transition the output audio will be silence. Default is 44100. @item start_time, st -Specify time for starting to apply the fade effect. Default is 0. -The accepted syntax is: -@example -[-]HH[:MM[:SS[.m...]]] -[-]S+[.m...] -@end example -See also the function @code{av_parse_time()}. -If set this option is used instead of @var{start_sample} one. +Specify the start time of the fade effect. Default is 0. +The value must be specified as a time duration; see +@ref{time duration syntax,,the Time duration section in the ffmpeg-utils(1) manual,ffmpeg-utils} +for the accepted syntax. +If set this option is used instead of @var{start_sample}. @item duration, d -Specify the duration for which the fade effect has to last. Default is 0. -The accepted syntax is: -@example -[-]HH[:MM[:SS[.m...]]] -[-]S+[.m...] -@end example -See also the function @code{av_parse_time()}. +Specify the duration of the fade effect. See +@ref{time duration syntax,,the Time duration section in the ffmpeg-utils(1) manual,ffmpeg-utils} +for the accepted syntax. At the end of the fade-in effect the output audio will have the same volume as the input audio, at the end of the fade-out transition the output audio will be silence. -If set this option is used instead of @var{nb_samples} one. +By default the duration is determined by @var{nb_samples}. +If set this option is used instead of @var{nb_samples}. @item curve Set curve for fade transition. @@ -1120,9 +1114,9 @@ The number of the first sample that should be output. The number of the first sample that should be dropped. @end table -@option{start}, @option{end}, @option{duration} are expressed as time -duration specifications, check the "Time duration" section in the -ffmpeg-utils manual. +@option{start}, @option{end}, and @option{duration} are expressed as time +duration specifications; see +@ref{time duration syntax,,the Time duration section in the ffmpeg-utils(1) manual,ffmpeg-utils}. Note that the first two sets of the start/end options and the @option{duration} option look at the frame timestamp, while the _sample options simply count the @@ -1637,9 +1631,9 @@ Set the number of samples per channel per each output frame, default is 1024. Only used if plugin have zero inputs. @item duration, d -Set the minimum duration of the sourced audio. See the function -@code{av_parse_time()} for the accepted format, also check the "Time duration" -section in the ffmpeg-utils manual. +Set the minimum duration of the sourced audio. See +@ref{time duration syntax,,the Time duration section in the ffmpeg-utils(1) manual,ffmpeg-utils} +for the accepted syntax. Note that the resulting duration may be greater than the specified duration, as the generated audio is always cut at the end of a complete frame. If not specified, or the expressed duration is negative, the audio is @@ -2189,8 +2183,9 @@ Set the channel layout. The number of channels in the specified layout must be equal to the number of specified expressions. @item duration, d -Set the minimum duration of the sourced audio. See the function -@code{av_parse_time()} for the accepted format. +Set the minimum duration of the sourced audio. See +@ref{time duration syntax,,the Time duration section in the ffmpeg-utils(1) manual,ffmpeg-utils} +for the accepted syntax. Note that the resulting duration may be greater than the specified duration, as the generated audio is always cut at the end of a complete frame. @@ -8546,9 +8541,10 @@ The number of the first frame that should be passed to the output. The number of the first frame that should be dropped. @end table -@option{start}, @option{end}, @option{duration} are expressed as time -duration specifications, check the "Time duration" section in the -ffmpeg-utils manual. +@option{start}, @option{end}, and @option{duration} are expressed as time +duration specifications; see +@ref{time duration syntax,,the Time duration section in the ffmpeg-utils(1) manual,ffmpeg-utils} +for the accepted syntax. Note that the first two sets of the start/end options and the @option{duration} option look at the frame timestamp, while the _frame variants simply count
[FFmpeg-cvslog] doc/filters.texi: fix filter name in examples
ffmpeg | branch: release/2.2 | Mark Harris | Mon Sep 1 12:32:33 2014 -0700| [85b829bff9c31178b2d70e39279a397795ce25cf] | committer: Michael Niedermayer doc/filters.texi: fix filter name in examples Signed-off-by: Michael Niedermayer (cherry picked from commit 1b3a98f137900b6c3eb9a4c177d0b25684d6d144) Signed-off-by: Michael Niedermayer > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=85b829bff9c31178b2d70e39279a397795ce25cf --- doc/filters.texi |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/filters.texi b/doc/filters.texi index 8bf29ec..b7a1b34 100644 --- a/doc/filters.texi +++ b/doc/filters.texi @@ -491,7 +491,7 @@ aeval=val(ch)/2:c=same @item Invert phase of the second channel: @example -eval=val(0)|-val(1) +aeval=val(0)|-val(1) @end example @end itemize @@ -8850,7 +8850,7 @@ Default value is "all", which will cycle through the list of all tests. For example the following: @example -testsrc=t=dc_luma +mptestsrc=t=dc_luma @end example will generate a "dc_luma" test pattern. ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] doc/filters.texi: fix filter name in examples
ffmpeg | branch: release/2.3 | Mark Harris | Mon Sep 1 12:32:33 2014 -0700| [08f56b846c23889e0a47f94d06baa3114a121b4b] | committer: Michael Niedermayer doc/filters.texi: fix filter name in examples Signed-off-by: Michael Niedermayer (cherry picked from commit 1b3a98f137900b6c3eb9a4c177d0b25684d6d144) Signed-off-by: Michael Niedermayer > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=08f56b846c23889e0a47f94d06baa3114a121b4b --- doc/filters.texi |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/filters.texi b/doc/filters.texi index 0f73314..784a972 100644 --- a/doc/filters.texi +++ b/doc/filters.texi @@ -491,7 +491,7 @@ aeval=val(ch)/2:c=same @item Invert phase of the second channel: @example -eval=val(0)|-val(1) +aeval=val(0)|-val(1) @end example @end itemize @@ -9318,7 +9318,7 @@ Default value is "all", which will cycle through the list of all tests. Some examples: @example -testsrc=t=dc_luma +mptestsrc=t=dc_luma @end example will generate a "dc_luma" test pattern. ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avformat/icodec: Fix crash probing fuzzed file
ffmpeg | branch: master | Mark Harris | Mon Feb 15 23:52:13 2016 -0800| [56e2cd9c042e05255aa28487694c29aaec023263] | committer: Michael Niedermayer avformat/icodec: Fix crash probing fuzzed file Avoid invalid memory read/crash when frame offset >= 0xfff8. Base64-encoded example: AAABADAwMDAwMAAAMAAwMDAw/P///w== (The previous commit verifies that p->buf_size >= 22.) Signed-off-by: Michael Niedermayer > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=56e2cd9c042e05255aa28487694c29aaec023263 --- libavformat/icodec.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/icodec.c b/libavformat/icodec.c index b247cb2..17acfb4 100644 --- a/libavformat/icodec.c +++ b/libavformat/icodec.c @@ -63,7 +63,7 @@ static int probe(AVProbeData *p) offset = AV_RL32(p->buf + 18 + i * 16); if (offset < 22) return FFMIN(i, AVPROBE_SCORE_MAX / 4); -if (offset + 8 > p->buf_size) +if (offset > p->buf_size - 8) continue; if (p->buf[offset] != 40 && AV_RB64(p->buf + offset) != PNGSIG) return FFMIN(i, AVPROBE_SCORE_MAX / 4); ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avformat/icodec: ico probe with unknown data
ffmpeg | branch: master | Mark Harris | Mon Feb 15 23:52:12 2016 -0800| [1b4fbf808082eaa6945e5fc2cda487573691e8e6] | committer: Michael Niedermayer avformat/icodec: ico probe with unknown data Fix cases where unknown data (data beyond p->buf_size) could produce a higher ico probe score than if the unknown data was known and valid. For example: Header: OK, 2 frames Frame 0: Unknown (offset points beyond end of probe buffer) Frame 1: Invalid Previously this example had a score of 25, even though the score would be 1 if the unknown frame was known to be valid or 0 if it was known to be invalid. For this example the score is now 1. Signed-off-by: Michael Niedermayer > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=1b4fbf808082eaa6945e5fc2cda487573691e8e6 --- libavformat/icodec.c | 16 ++-- 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/libavformat/icodec.c b/libavformat/icodec.c index 6ddb901..b247cb2 100644 --- a/libavformat/icodec.c +++ b/libavformat/icodec.c @@ -45,11 +45,14 @@ typedef struct { static int probe(AVProbeData *p) { -unsigned i, frames = AV_RL16(p->buf + 4); +unsigned i, frames, checked = 0; -if (AV_RL16(p->buf) || AV_RL16(p->buf + 2) != 1 || !frames) +if (p->buf_size < 22 || AV_RL16(p->buf) || AV_RL16(p->buf + 2) != 1) return 0; -for (i = 0; i < frames; i++) { +frames = AV_RL16(p->buf + 4); +if (!frames) +return 0; +for (i = 0; i < frames && i * 16 + 22 <= p->buf_size; i++) { unsigned offset; if (AV_RL16(p->buf + 10 + i * 16) & ~1) return FFMIN(i, AVPROBE_SCORE_MAX / 4); @@ -61,13 +64,14 @@ static int probe(AVProbeData *p) if (offset < 22) return FFMIN(i, AVPROBE_SCORE_MAX / 4); if (offset + 8 > p->buf_size) -return AVPROBE_SCORE_MAX / 4 + FFMIN(i, 1); +continue; if (p->buf[offset] != 40 && AV_RB64(p->buf + offset) != PNGSIG) return FFMIN(i, AVPROBE_SCORE_MAX / 4); -if (i * 16 + 6 > p->buf_size) -return AVPROBE_SCORE_MAX / 4 + FFMIN(i, 1); +checked++; } +if (checked < frames) +return AVPROBE_SCORE_MAX / 4 + FFMIN(checked, 1); return AVPROBE_SCORE_MAX / 2 + 1; } ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] sdp: fix opus sprop-stereo fmtp syntax
ffmpeg | branch: master | Mark Harris | Mon Feb 29 20:08:14 2016 -0800| [c3bb6166dd05801e86a959085cdffbc3fb1ac46d] | committer: Michael Niedermayer sdp: fix opus sprop-stereo fmtp syntax Signed-off-by: Michael Niedermayer > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=c3bb6166dd05801e86a959085cdffbc3fb1ac46d --- libavformat/sdp.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/sdp.c b/libavformat/sdp.c index 2ab37a8..368402b 100644 --- a/libavformat/sdp.c +++ b/libavformat/sdp.c @@ -706,7 +706,7 @@ static char *sdp_write_media_attributes(char *buff, int size, AVCodecContext *c, av_strlcatf(buff, size, "a=rtpmap:%d opus/48000/2\r\n", payload_type); if (c->channels == 2) { -av_strlcatf(buff, size, "a=fmtp:%d sprop-stereo:1\r\n", +av_strlcatf(buff, size, "a=fmtp:%d sprop-stereo=1\r\n", payload_type); } break; ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avformat/dump: Fix context/level for payload dump
ffmpeg | branch: master | Mark Harris | Sat Mar 5 09:10:00 2016 -0800| [238ddd6482d7aea2e917760a9bef291030a11e61] | committer: Michael Niedermayer avformat/dump: Fix context/level for payload dump Use the context and level specified to av_pkt_dump_log2(), instead of panic level (0), for dumping packet payload. Signed-off-by: Michael Niedermayer > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=238ddd6482d7aea2e917760a9bef291030a11e61 --- libavformat/dump.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/dump.c b/libavformat/dump.c index 9e7c12b..86bb82d 100644 --- a/libavformat/dump.c +++ b/libavformat/dump.c @@ -101,7 +101,7 @@ static void pkt_dump_internal(void *avcl, FILE *f, int level, const AVPacket *pk HEXDUMP_PRINT("\n"); HEXDUMP_PRINT(" size=%d\n", pkt->size); if (dump_payload) -av_hex_dump(f, pkt->data, pkt->size); +hex_dump_internal(avcl, f, level, pkt->data, pkt->size); } void av_pkt_dump2(FILE *f, const AVPacket *pkt, int dump_payload, const AVStream *st) ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] sdp: fix opus sprop-stereo fmtp syntax
ffmpeg | branch: master | Mark Harris | Mon Feb 29 20:09:53 2016 -0800| [4d13bcceb9a1820f8e9b2c89e00816d3db41b716] | committer: Martin Storsjö sdp: fix opus sprop-stereo fmtp syntax Signed-off-by: Martin Storsjö > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=4d13bcceb9a1820f8e9b2c89e00816d3db41b716 --- libavformat/sdp.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/sdp.c b/libavformat/sdp.c index d21ffac..b513cca 100644 --- a/libavformat/sdp.c +++ b/libavformat/sdp.c @@ -692,7 +692,7 @@ static char *sdp_write_media_attributes(char *buff, int size, AVCodecParameters av_strlcatf(buff, size, "a=rtpmap:%d opus/48000/2\r\n", payload_type); if (p->channels == 2) { -av_strlcatf(buff, size, "a=fmtp:%d sprop-stereo:1\r\n", +av_strlcatf(buff, size, "a=fmtp:%d sprop-stereo=1\r\n", payload_type); } break; ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avutil/mem: Fix invalid use of av_alloc_size
ffmpeg | branch: master | Mark Harris | Sat Nov 24 13:02:02 2018 -0800| [4361293fcf59edb56879c36edcd25f0a91e0edf8] | committer: Michael Niedermayer avutil/mem: Fix invalid use of av_alloc_size The alloc_size attribute is valid only on functions that return a pointer. GCC 9 (not yet released) warns about invalid usage: ./libavutil/mem.h:342:1: warning: 'alloc_size' attribute ignored on a function returning int' [-Wattributes] 342 | av_alloc_size(2, 3) int av_reallocp_array(void *ptr, size_t nmemb, size_t size); | ^ Signed-off-by: Michael Niedermayer > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=4361293fcf59edb56879c36edcd25f0a91e0edf8 --- libavutil/mem.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavutil/mem.h b/libavutil/mem.h index 55ae573ac9..5fb1a02dd9 100644 --- a/libavutil/mem.h +++ b/libavutil/mem.h @@ -339,7 +339,7 @@ av_alloc_size(2, 3) void *av_realloc_array(void *ptr, size_t nmemb, size_t size) * @warning Unlike av_malloc(), the allocated memory is not guaranteed to be * correctly aligned. */ -av_alloc_size(2, 3) int av_reallocp_array(void *ptr, size_t nmemb, size_t size); +int av_reallocp_array(void *ptr, size_t nmemb, size_t size); /** * Reallocate the given buffer if it is not large enough, otherwise do nothing. ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avfilter/vf_chromashift: Fix mixed declaration and code
ffmpeg | branch: master | Mark Harris | Sat Nov 24 19:17:40 2018 -0800| [8108064043bfb98cbc5a5bab9da4229be5f6e846] | committer: Michael Niedermayer avfilter/vf_chromashift: Fix mixed declaration and code Reviewed-by: Paul B Mahol Signed-off-by: Michael Niedermayer > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=8108064043bfb98cbc5a5bab9da4229be5f6e846 --- libavfilter/vf_chromashift.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libavfilter/vf_chromashift.c b/libavfilter/vf_chromashift.c index 068c3c1b68..d073256b99 100644 --- a/libavfilter/vf_chromashift.c +++ b/libavfilter/vf_chromashift.c @@ -76,13 +76,14 @@ static int query_formats(AVFilterContext *ctx) AV_PIX_FMT_NONE }; const enum AVPixelFormat *pix_fmts; +AVFilterFormats *fmts_list; if (!strcmp(ctx->filter->name, "rgbashift")) pix_fmts = rgb_pix_fmts; else pix_fmts = yuv_pix_fmts; -AVFilterFormats *fmts_list = ff_make_format_list(pix_fmts); +fmts_list = ff_make_format_list(pix_fmts); if (!fmts_list) return AVERROR(ENOMEM); return ff_set_common_formats(ctx, fmts_list); ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avformat/vivo: Don't log null value
ffmpeg | branch: master | Mark Harris | Sat Nov 24 19:18:43 2018 -0800| [01dc152a92d3ea144ac12ef25f41cc8a44f4b4ef] | committer: Michael Niedermayer avformat/vivo: Don't log null value Reviewed-by: Paul B Mahol Signed-off-by: Michael Niedermayer > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=01dc152a92d3ea144ac12ef25f41cc8a44f4b4ef --- libavformat/vivo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/vivo.c b/libavformat/vivo.c index c9e9c37f37..9b9189f307 100644 --- a/libavformat/vivo.c +++ b/libavformat/vivo.c @@ -166,7 +166,7 @@ static int vivo_read_header(AVFormatContext *s) value = strchr(key, ':'); if (!value) { av_log(s, AV_LOG_WARNING, "missing colon in key:value pair '%s'\n", - value); + key); continue; } ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avutil/mem: Fix invalid use of av_alloc_size
ffmpeg | branch: release/3.0 | Mark Harris | Sat Nov 24 13:02:02 2018 -0800| [b858bcbbf6c14285c840f78dfe8a0e7b9d68997a] | committer: James Almer avutil/mem: Fix invalid use of av_alloc_size The alloc_size attribute is valid only on functions that return a pointer. GCC 9 (not yet released) warns about invalid usage: ./libavutil/mem.h:342:1: warning: 'alloc_size' attribute ignored on a function returning int' [-Wattributes] 342 | av_alloc_size(2, 3) int av_reallocp_array(void *ptr, size_t nmemb, size_t size); | ^ Signed-off-by: Michael Niedermayer (cherry picked from commit 4361293fcf59edb56879c36edcd25f0a91e0edf8) > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=b858bcbbf6c14285c840f78dfe8a0e7b9d68997a --- libavutil/mem.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavutil/mem.h b/libavutil/mem.h index d25b3229b7..376fd2e07c 100644 --- a/libavutil/mem.h +++ b/libavutil/mem.h @@ -183,7 +183,7 @@ av_alloc_size(2, 3) void *av_realloc_array(void *ptr, size_t nmemb, size_t size) * The situation is undefined according to POSIX and may crash with * some libc implementations. */ -av_alloc_size(2, 3) int av_reallocp_array(void *ptr, size_t nmemb, size_t size); +int av_reallocp_array(void *ptr, size_t nmemb, size_t size); /** * Free a memory block which has been allocated with av_malloc(z)() or ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog To unsubscribe, visit link above, or email ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".
[FFmpeg-cvslog] avutil/mem: Fix invalid use of av_alloc_size
ffmpeg | branch: release/3.4 | Mark Harris | Sat Nov 24 13:02:02 2018 -0800| [29362d5f9a4cc99a783e6c0e362644219e61bb89] | committer: James Almer avutil/mem: Fix invalid use of av_alloc_size The alloc_size attribute is valid only on functions that return a pointer. GCC 9 (not yet released) warns about invalid usage: ./libavutil/mem.h:342:1: warning: 'alloc_size' attribute ignored on a function returning int' [-Wattributes] 342 | av_alloc_size(2, 3) int av_reallocp_array(void *ptr, size_t nmemb, size_t size); | ^ Signed-off-by: Michael Niedermayer (cherry picked from commit 4361293fcf59edb56879c36edcd25f0a91e0edf8) > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=29362d5f9a4cc99a783e6c0e362644219e61bb89 --- libavutil/mem.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavutil/mem.h b/libavutil/mem.h index 527cd03191..d6f9c81549 100644 --- a/libavutil/mem.h +++ b/libavutil/mem.h @@ -338,7 +338,7 @@ av_alloc_size(2, 3) void *av_realloc_array(void *ptr, size_t nmemb, size_t size) * @warning Unlike av_malloc(), the allocated memory is not guaranteed to be * correctly aligned. */ -av_alloc_size(2, 3) int av_reallocp_array(void *ptr, size_t nmemb, size_t size); +int av_reallocp_array(void *ptr, size_t nmemb, size_t size); /** * Reallocate the given buffer if it is not large enough, otherwise do nothing. ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog To unsubscribe, visit link above, or email ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".
[FFmpeg-cvslog] avutil/mem: Fix invalid use of av_alloc_size
ffmpeg | branch: release/4.0 | Mark Harris | Sat Nov 24 13:02:02 2018 -0800| [dbca455d7e367c131b2275ece20e9b6db4dd5434] | committer: James Almer avutil/mem: Fix invalid use of av_alloc_size The alloc_size attribute is valid only on functions that return a pointer. GCC 9 (not yet released) warns about invalid usage: ./libavutil/mem.h:342:1: warning: 'alloc_size' attribute ignored on a function returning int' [-Wattributes] 342 | av_alloc_size(2, 3) int av_reallocp_array(void *ptr, size_t nmemb, size_t size); | ^ Signed-off-by: Michael Niedermayer (cherry picked from commit 4361293fcf59edb56879c36edcd25f0a91e0edf8) > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=dbca455d7e367c131b2275ece20e9b6db4dd5434 --- libavutil/mem.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavutil/mem.h b/libavutil/mem.h index 7e0b12a8a7..b5c637ecf3 100644 --- a/libavutil/mem.h +++ b/libavutil/mem.h @@ -339,7 +339,7 @@ av_alloc_size(2, 3) void *av_realloc_array(void *ptr, size_t nmemb, size_t size) * @warning Unlike av_malloc(), the allocated memory is not guaranteed to be * correctly aligned. */ -av_alloc_size(2, 3) int av_reallocp_array(void *ptr, size_t nmemb, size_t size); +int av_reallocp_array(void *ptr, size_t nmemb, size_t size); /** * Reallocate the given buffer if it is not large enough, otherwise do nothing. ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog To unsubscribe, visit link above, or email ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".
[FFmpeg-cvslog] avutil/mem: Fix invalid use of av_alloc_size
ffmpeg | branch: release/3.2 | Mark Harris | Sat Nov 24 13:02:02 2018 -0800| [5fd65ebf28d9e8f2c9aadf8d8ba08d181b8ddfc1] | committer: James Almer avutil/mem: Fix invalid use of av_alloc_size The alloc_size attribute is valid only on functions that return a pointer. GCC 9 (not yet released) warns about invalid usage: ./libavutil/mem.h:342:1: warning: 'alloc_size' attribute ignored on a function returning int' [-Wattributes] 342 | av_alloc_size(2, 3) int av_reallocp_array(void *ptr, size_t nmemb, size_t size); | ^ Signed-off-by: Michael Niedermayer (cherry picked from commit 4361293fcf59edb56879c36edcd25f0a91e0edf8) > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=5fd65ebf28d9e8f2c9aadf8d8ba08d181b8ddfc1 --- libavutil/mem.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavutil/mem.h b/libavutil/mem.h index f9d8884788..5d505d22c1 100644 --- a/libavutil/mem.h +++ b/libavutil/mem.h @@ -335,7 +335,7 @@ av_alloc_size(2, 3) void *av_realloc_array(void *ptr, size_t nmemb, size_t size) * @warning Unlike av_malloc(), the allocated memory is not guaranteed to be * correctly aligned. */ -av_alloc_size(2, 3) int av_reallocp_array(void *ptr, size_t nmemb, size_t size); +int av_reallocp_array(void *ptr, size_t nmemb, size_t size); /** * Reallocate the given buffer if it is not large enough, otherwise do nothing. ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog To unsubscribe, visit link above, or email ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".
[FFmpeg-cvslog] avutil/mem: Fix invalid use of av_alloc_size
ffmpeg | branch: release/3.3 | Mark Harris | Sat Nov 24 13:02:02 2018 -0800| [9d3509f4015f422584fe748ff66b0783d86c62e1] | committer: James Almer avutil/mem: Fix invalid use of av_alloc_size The alloc_size attribute is valid only on functions that return a pointer. GCC 9 (not yet released) warns about invalid usage: ./libavutil/mem.h:342:1: warning: 'alloc_size' attribute ignored on a function returning int' [-Wattributes] 342 | av_alloc_size(2, 3) int av_reallocp_array(void *ptr, size_t nmemb, size_t size); | ^ Signed-off-by: Michael Niedermayer (cherry picked from commit 4361293fcf59edb56879c36edcd25f0a91e0edf8) > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=9d3509f4015f422584fe748ff66b0783d86c62e1 --- libavutil/mem.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavutil/mem.h b/libavutil/mem.h index 527cd03191..d6f9c81549 100644 --- a/libavutil/mem.h +++ b/libavutil/mem.h @@ -338,7 +338,7 @@ av_alloc_size(2, 3) void *av_realloc_array(void *ptr, size_t nmemb, size_t size) * @warning Unlike av_malloc(), the allocated memory is not guaranteed to be * correctly aligned. */ -av_alloc_size(2, 3) int av_reallocp_array(void *ptr, size_t nmemb, size_t size); +int av_reallocp_array(void *ptr, size_t nmemb, size_t size); /** * Reallocate the given buffer if it is not large enough, otherwise do nothing. ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog To unsubscribe, visit link above, or email ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".
[FFmpeg-cvslog] avutil/mem: Fix invalid use of av_alloc_size
ffmpeg | branch: release/4.1 | Mark Harris | Sat Nov 24 13:02:02 2018 -0800| [0c904c0d3ff85ed5f634ff3e3202d5c1cd4a95d1] | committer: James Almer avutil/mem: Fix invalid use of av_alloc_size The alloc_size attribute is valid only on functions that return a pointer. GCC 9 (not yet released) warns about invalid usage: ./libavutil/mem.h:342:1: warning: 'alloc_size' attribute ignored on a function returning int' [-Wattributes] 342 | av_alloc_size(2, 3) int av_reallocp_array(void *ptr, size_t nmemb, size_t size); | ^ Signed-off-by: Michael Niedermayer (cherry picked from commit 4361293fcf59edb56879c36edcd25f0a91e0edf8) > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=0c904c0d3ff85ed5f634ff3e3202d5c1cd4a95d1 --- libavutil/mem.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavutil/mem.h b/libavutil/mem.h index 7e0b12a8a7..b5c637ecf3 100644 --- a/libavutil/mem.h +++ b/libavutil/mem.h @@ -339,7 +339,7 @@ av_alloc_size(2, 3) void *av_realloc_array(void *ptr, size_t nmemb, size_t size) * @warning Unlike av_malloc(), the allocated memory is not guaranteed to be * correctly aligned. */ -av_alloc_size(2, 3) int av_reallocp_array(void *ptr, size_t nmemb, size_t size); +int av_reallocp_array(void *ptr, size_t nmemb, size_t size); /** * Reallocate the given buffer if it is not large enough, otherwise do nothing. ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog To unsubscribe, visit link above, or email ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".
[FFmpeg-cvslog] avutil/mem: Fix invalid use of av_alloc_size
ffmpeg | branch: release/2.8 | Mark Harris | Sat Nov 24 13:02:02 2018 -0800| [266b784bb3698120dfea9de6dce562df9bebd845] | committer: James Almer avutil/mem: Fix invalid use of av_alloc_size The alloc_size attribute is valid only on functions that return a pointer. GCC 9 (not yet released) warns about invalid usage: ./libavutil/mem.h:342:1: warning: 'alloc_size' attribute ignored on a function returning int' [-Wattributes] 342 | av_alloc_size(2, 3) int av_reallocp_array(void *ptr, size_t nmemb, size_t size); | ^ Signed-off-by: Michael Niedermayer (cherry picked from commit 4361293fcf59edb56879c36edcd25f0a91e0edf8) > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=266b784bb3698120dfea9de6dce562df9bebd845 --- libavutil/mem.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavutil/mem.h b/libavutil/mem.h index 2a1e36d69f..83b714618b 100644 --- a/libavutil/mem.h +++ b/libavutil/mem.h @@ -182,7 +182,7 @@ av_alloc_size(2, 3) void *av_realloc_array(void *ptr, size_t nmemb, size_t size) * The situation is undefined according to POSIX and may crash with * some libc implementations. */ -av_alloc_size(2, 3) int av_reallocp_array(void *ptr, size_t nmemb, size_t size); +int av_reallocp_array(void *ptr, size_t nmemb, size_t size); /** * Free a memory block which has been allocated with av_malloc(z)() or ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog To unsubscribe, visit link above, or email ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".
[FFmpeg-cvslog] avutil/mem: Fix invalid use of av_alloc_size
ffmpeg | branch: release/3.1 | Mark Harris | Sat Nov 24 13:02:02 2018 -0800| [6f6cd2e29df5ba0c957772a101790db22c7cab94] | committer: James Almer avutil/mem: Fix invalid use of av_alloc_size The alloc_size attribute is valid only on functions that return a pointer. GCC 9 (not yet released) warns about invalid usage: ./libavutil/mem.h:342:1: warning: 'alloc_size' attribute ignored on a function returning int' [-Wattributes] 342 | av_alloc_size(2, 3) int av_reallocp_array(void *ptr, size_t nmemb, size_t size); | ^ Signed-off-by: Michael Niedermayer (cherry picked from commit 4361293fcf59edb56879c36edcd25f0a91e0edf8) > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=6f6cd2e29df5ba0c957772a101790db22c7cab94 --- libavutil/mem.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavutil/mem.h b/libavutil/mem.h index d25b3229b7..376fd2e07c 100644 --- a/libavutil/mem.h +++ b/libavutil/mem.h @@ -183,7 +183,7 @@ av_alloc_size(2, 3) void *av_realloc_array(void *ptr, size_t nmemb, size_t size) * The situation is undefined according to POSIX and may crash with * some libc implementations. */ -av_alloc_size(2, 3) int av_reallocp_array(void *ptr, size_t nmemb, size_t size); +int av_reallocp_array(void *ptr, size_t nmemb, size_t size); /** * Free a memory block which has been allocated with av_malloc(z)() or ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog To unsubscribe, visit link above, or email ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".