[FFmpeg-cvslog] avcodec/h264_refs: Do not set reference to things which dont exist
ffmpeg | branch: release/2.2 | Michael Niedermayer michae...@gmx.at | Sat Apr 4 18:08:23 2015 +0200| [6496cbee695bbe834bcaffc0e9375d93ff77eeda] | committer: Michael Niedermayer avcodec/h264_refs: Do not set reference to things which dont exist Fixes deadlock Fixes Ticket4428 Fixes Ticket4429 Signed-off-by: Michael Niedermayer michae...@gmx.at (cherry picked from commit 429de043202286a2b5bcc082cc02de860b734db2) Signed-off-by: Michael Niedermayer michae...@gmx.at http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=6496cbee695bbe834bcaffc0e9375d93ff77eeda --- libavcodec/h264_refs.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/h264_refs.c b/libavcodec/h264_refs.c index 1cd8a6d..b08828c 100644 --- a/libavcodec/h264_refs.c +++ b/libavcodec/h264_refs.c @@ -703,7 +703,7 @@ int ff_h264_execute_ref_pic_marking(H264Context *h, MMCO *mmco, int mmco_count) */ if (h-short_ref_count h-short_ref[0] == h-cur_pic_ptr) { /* Just mark the second field valid */ -h-cur_pic_ptr-reference = PICT_FRAME; +h-cur_pic_ptr-reference |= h-picture_structure; } else if (h-cur_pic_ptr-long_ref) { av_log(h-avctx, AV_LOG_ERROR, illegal short term reference assignment for second field ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] tests/fate.sh: report different status for different errors
ffmpeg | branch: release/2.2 | Timothy Gu timothyg...@gmail.com | Mon Jun 9 21:46:37 2014 -0700| [83ac312c3cbfdddea25b84e5b7ea595ef073a029] | committer: Michael Niedermayer tests/fate.sh: report different status for different errors The order of error codes will be useful in my future fateserver patches. Signed-off-by: Timothy Gu timothyg...@gmail.com Signed-off-by: Michael Niedermayer michae...@gmx.at (cherry picked from commit cc0057a31c7097839f9c4e4da61e2933b5b0e055) Signed-off-by: Timothy Gu timothyg...@gmail.com http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=83ac312c3cbfdddea25b84e5b7ea595ef073a029 --- tests/fate.sh |6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/fate.sh b/tests/fate.sh index f371291..38458c7 100755 --- a/tests/fate.sh +++ b/tests/fate.sh @@ -111,8 +111,8 @@ echo ${version} version-$slot rm -rf ${build} *.log mkdir -p ${build} -configure configure.log 21 || fail $? error configuring -compile compile.log 21 || fail $? error compiling -fate test.log 21 || fail $? error testing +configure configure.log 21 || fail 3 error configuring +compile compile.log 21 || fail 2 error compiling +fate test.log 21 || fail 1 error testing report 0 success clean ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avcodec/h264: Fix race between slices where one overwrites data from the next
ffmpeg | branch: release/2.2 | Michael Niedermayer michae...@gmx.at | Tue Apr 7 00:40:21 2015 +0200| [3852b172e7de8fee4b78ff3f5026a9a13c7329d5] | committer: Michael Niedermayer avcodec/h264: Fix race between slices where one overwrites data from the next Fixes non deterministic crash in ticket4408/fuzz2.264 Likely fixes other samples as well Signed-off-by: Michael Niedermayer michae...@gmx.at (cherry picked from commit 43b434210e597d484aef57c4139c3126d22b7e2b) Conflicts: libavcodec/h264.h libavcodec/h264_slice.c (cherry picked from commit dbbc42858e87cdd04e6c3b7694f8b394d4bfcdc6) Conflicts: libavcodec/h264_slice.c http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=3852b172e7de8fee4b78ff3f5026a9a13c7329d5 --- libavcodec/h264.c | 43 ++- libavcodec/h264.h |1 + 2 files changed, 39 insertions(+), 5 deletions(-) diff --git a/libavcodec/h264.c b/libavcodec/h264.c index 155877b..30b20c9 100644 --- a/libavcodec/h264.c +++ b/libavcodec/h264.c @@ -4635,8 +4635,17 @@ static int decode_slice(struct AVCodecContext *avctx, void *arg) for (;;) { // START_TIMER -int ret = ff_h264_decode_mb_cabac(h); -int eos; +int ret, eos; + +if (h-mb_x + h-mb_y * h-mb_width = h-mb_index_end) { +av_log(h-avctx, AV_LOG_ERROR, Slice overlaps next at %d\n, + h-mb_index_end); +er_add_slice(h, h-resync_mb_x, h-resync_mb_y, h-mb_x, + h-mb_y, ER_MB_ERROR); +return AVERROR_INVALIDDATA; +} + +ret = ff_h264_decode_mb_cabac(h); // STOP_TIMER(decode_mb_cabac) if (ret = 0) @@ -4698,7 +4707,17 @@ static int decode_slice(struct AVCodecContext *avctx, void *arg) } } else { for (;;) { -int ret = ff_h264_decode_mb_cavlc(h); +int ret; + +if (h-mb_x + h-mb_y * h-mb_width = h-mb_index_end) { +av_log(h-avctx, AV_LOG_ERROR, Slice overlaps next at %d\n, + h-mb_index_end); +er_add_slice(h, h-resync_mb_x, h-resync_mb_y, h-mb_x, + h-mb_y, ER_MB_ERROR); +return AVERROR_INVALIDDATA; +} + +ret = ff_h264_decode_mb_cavlc(h); if (ret = 0) ff_h264_hl_decode_mb(h); @@ -4789,19 +4808,33 @@ static int execute_decode_slices(H264Context *h, unsigned context_count) av_assert0(h-mb_y h-mb_height); +h-mb_index_end = INT_MAX; + if (h-avctx-hwaccel || h-avctx-codec-capabilities CODEC_CAP_HWACCEL_VDPAU) return 0; if (context_count == 1) { return decode_slice(avctx, h); } else { +int j, mb_index; av_assert0(context_count 0); -for (i = 1; i context_count; i++) { +for (i = 0; i context_count; i++) { +int mb_index_end = h-mb_width * h-mb_height; hx = h-thread_context[i]; -if (CONFIG_ERROR_RESILIENCE) { +mb_index = hx-resync_mb_x + hx-resync_mb_y * h-mb_width; +if (CONFIG_ERROR_RESILIENCE i) { hx-er.error_count = 0; } hx-x264_build = h-x264_build; +for (j = 0; j context_count; j++) { +H264Context *sl2 = h-thread_context[j]; +int mb_index2 = sl2-resync_mb_x + sl2-resync_mb_y * h-mb_width; + +if (i==j || mb_index mb_index2) +continue; +mb_index_end = FFMIN(mb_index_end, mb_index2); +} +hx-mb_index_end = mb_index_end; } avctx-execute(avctx, decode_slice, h-thread_context, diff --git a/libavcodec/h264.h b/libavcodec/h264.h index 66c1473..6a3e570 100644 --- a/libavcodec/h264.h +++ b/libavcodec/h264.h @@ -488,6 +488,7 @@ typedef struct H264Context { int mb_x, mb_y; int resync_mb_x; int resync_mb_y; +int mb_index_end; int mb_skip_run; int mb_height, mb_width; int mb_stride; ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avcodec/msrledec: restructure msrle_decode_pal4() based on the line number instead of the pixel pointer
ffmpeg | branch: release/2.2 | Michael Niedermayer michae...@gmx.at | Tue Mar 24 15:50:12 2015 +0100| [33877cd276f99fc234b5269d9d158ce71e50d363] | committer: Michael Niedermayer avcodec/msrledec: restructure msrle_decode_pal4() based on the line number instead of the pixel pointer Fixes out of array access Fixes: da14e86d8462be6493eab16bc2d40f88/asan_heap-oob_204cfd2_528_cov_340150052_COMPRESS.BMP Found-by: Mateusz j00ru Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer michae...@gmx.at (cherry picked from commit f7e1367f58263593e6cee3c282f7277d7ee9d553) Signed-off-by: Michael Niedermayer michae...@gmx.at http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=33877cd276f99fc234b5269d9d158ce71e50d363 --- libavcodec/msrledec.c | 25 +++-- 1 file changed, 11 insertions(+), 14 deletions(-) diff --git a/libavcodec/msrledec.c b/libavcodec/msrledec.c index 4d3da5b..deb6f86 100644 --- a/libavcodec/msrledec.c +++ b/libavcodec/msrledec.c @@ -37,16 +37,14 @@ static int msrle_decode_pal4(AVCodecContext *avctx, AVPicture *pic, unsigned char extra_byte, odd_pixel; unsigned char stream_byte; unsigned int pixel_ptr = 0; -int row_dec = pic-linesize[0]; -int row_ptr = (avctx-height - 1) * row_dec; -int frame_size = row_dec * avctx-height; +int line = avctx-height - 1; int i; -while (row_ptr = 0) { +while (line = 0 pixel_ptr = avctx-width) { if (bytestream2_get_bytes_left(gb) = 0) { av_log(avctx, AV_LOG_ERROR, - MS RLE: bytestream overrun, %d rows left\n, - row_ptr); + MS RLE: bytestream overrun, %dx%d left\n, + avctx-width - pixel_ptr, line); return AVERROR_INVALIDDATA; } rle_code = stream_byte = bytestream2_get_byteu(gb); @@ -55,7 +53,7 @@ static int msrle_decode_pal4(AVCodecContext *avctx, AVPicture *pic, stream_byte = bytestream2_get_byte(gb); if (stream_byte == 0) { /* line is done, goto the next one */ -row_ptr -= row_dec; +line--; pixel_ptr = 0; } else if (stream_byte == 1) { /* decode is done */ @@ -65,13 +63,12 @@ static int msrle_decode_pal4(AVCodecContext *avctx, AVPicture *pic, stream_byte = bytestream2_get_byte(gb); pixel_ptr += stream_byte; stream_byte = bytestream2_get_byte(gb); -row_ptr -= stream_byte * row_dec; } else { // copy pixels from encoded stream odd_pixel = stream_byte 1; rle_code = (stream_byte + 1) / 2; extra_byte = rle_code 0x01; -if (row_ptr + pixel_ptr + stream_byte frame_size || +if (pixel_ptr + 2*rle_code - odd_pixel avctx-width || bytestream2_get_bytes_left(gb) rle_code) { av_log(avctx, AV_LOG_ERROR, MS RLE: frame/stream ptr just went out of bounds (copy)\n); @@ -82,13 +79,13 @@ static int msrle_decode_pal4(AVCodecContext *avctx, AVPicture *pic, if (pixel_ptr = avctx-width) break; stream_byte = bytestream2_get_byteu(gb); -pic-data[0][row_ptr + pixel_ptr] = stream_byte 4; +pic-data[0][line * pic-linesize[0] + pixel_ptr] = stream_byte 4; pixel_ptr++; if (i + 1 == rle_code odd_pixel) break; if (pixel_ptr = avctx-width) break; -pic-data[0][row_ptr + pixel_ptr] = stream_byte 0x0F; +pic-data[0][line * pic-linesize[0] + pixel_ptr] = stream_byte 0x0F; pixel_ptr++; } @@ -98,7 +95,7 @@ static int msrle_decode_pal4(AVCodecContext *avctx, AVPicture *pic, } } else { // decode a run of data -if (row_ptr + pixel_ptr + stream_byte frame_size) { +if (pixel_ptr + rle_code avctx-width + 1) { av_log(avctx, AV_LOG_ERROR, MS RLE: frame ptr just went out of bounds (run)\n); return AVERROR_INVALIDDATA; @@ -108,9 +105,9 @@ static int msrle_decode_pal4(AVCodecContext *avctx, AVPicture *pic, if (pixel_ptr = avctx-width) break; if ((i 1) == 0) -pic-data[0][row_ptr + pixel_ptr] = stream_byte 4; +pic-data[0][line * pic-linesize[0] + pixel_ptr] = stream_byte 4; else -pic-data[0][row_ptr + pixel_ptr] = stream_byte 0x0F; +pic-data[0][line * pic-linesize[0] + pixel_ptr] = stream_byte 0x0F; pixel_ptr++; } }
[FFmpeg-cvslog] avcodec/h264: finish previous slices before switching to single thread mode
ffmpeg | branch: release/2.2 | Michael Niedermayer michae...@gmx.at | Tue Apr 7 02:47:36 2015 +0200| [8f026e2b388a9638c8d4ae13c44e583626c71d5c] | committer: Michael Niedermayer avcodec/h264: finish previous slices before switching to single thread mode Fixes null pointer dereference Fixes Ticket4438 Signed-off-by: Michael Niedermayer michae...@gmx.at (cherry picked from commit c4b2017ba66e1623da9f527704c61c86a6e74844) Conflicts: libavcodec/h264.c (cherry picked from commit 09cc7aee3f4d1bd1d7107d38520f782c62c14036) Conflicts: libavcodec/h264.c http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=8f026e2b388a9638c8d4ae13c44e583626c71d5c --- libavcodec/h264.c |6 ++ 1 file changed, 6 insertions(+) diff --git a/libavcodec/h264.c b/libavcodec/h264.c index 30b20c9..61fd02f 100644 --- a/libavcodec/h264.c +++ b/libavcodec/h264.c @@ -5221,6 +5221,12 @@ again: av_log(h-avctx, AV_LOG_ERROR, decode_slice_header error\n); h-ref_count[0] = h-ref_count[1] = h-list_count = 0; } else if (err == 1) { +if (context_count 1) { +ret = execute_decode_slices(h, context_count - 1); +if (ret 0 (h-avctx-err_recognition AV_EF_EXPLODE)) +goto end; +context_count = 0; +} /* Slice could not be decoded in parallel mode, copy down * NAL unit stuff to context 0 and restart. Note that * rbsp_buffer is not transferred, but since we no longer ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avcodec/hevc_ps: More complete window reset
ffmpeg | branch: release/2.2 | Michael Niedermayer michae...@gmx.at | Thu Nov 27 15:03:35 2014 +0100| [58e055cb262e7259a6a0c5a231ed7bfeacc8ad58] | committer: Michael Niedermayer avcodec/hevc_ps: More complete window reset Fixes out of array read Fixes: signal_sigsegv_35bcf26_471_cov_2806540268_CAINIT_A_SHARP_4.bit Found-by: Mateusz j00ru Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer michae...@gmx.at (cherry picked from commit 57e5812198aada016e9ba4149123c541f8c8a7ec) Signed-off-by: Michael Niedermayer michae...@gmx.at http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=58e055cb262e7259a6a0c5a231ed7bfeacc8ad58 --- libavcodec/hevc_ps.c |6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/libavcodec/hevc_ps.c b/libavcodec/hevc_ps.c index be1adb1..aa9153f 100644 --- a/libavcodec/hevc_ps.c +++ b/libavcodec/hevc_ps.c @@ -907,10 +907,8 @@ int ff_hevc_decode_nal_sps(HEVCContext *s) } av_log(s-avctx, AV_LOG_WARNING, Displaying the whole video surface.\n); -sps-pic_conf_win.left_offset = -sps-pic_conf_win.right_offset = -sps-pic_conf_win.top_offset= -sps-pic_conf_win.bottom_offset = 0; +memset(sps-pic_conf_win, 0, sizeof(sps-pic_conf_win)); +memset(sps-output_window, 0, sizeof(sps-output_window)); sps-output_width = sps-width; sps-output_height = sps-height; } ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avcodec/dnxhddec: Check that the frame is interlaced before using cur_field
ffmpeg | branch: release/2.2 | Michael Niedermayer michae...@gmx.at | Thu Mar 19 23:28:39 2015 +0100| [3ce32f640115547909e062736885d1062233a67a] | committer: Michael Niedermayer avcodec/dnxhddec: Check that the frame is interlaced before using cur_field Fixes Ticket4227 Signed-off-by: Michael Niedermayer michae...@gmx.at (cherry picked from commit 2c660e34cf3c2b77cd2bef6f292920334dfd9192) Signed-off-by: Michael Niedermayer michae...@gmx.at http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=3ce32f640115547909e062736885d1062233a67a --- libavcodec/dnxhddec.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/dnxhddec.c b/libavcodec/dnxhddec.c index f00d866..8999240 100644 --- a/libavcodec/dnxhddec.c +++ b/libavcodec/dnxhddec.c @@ -349,7 +349,7 @@ static int dnxhd_decode_macroblock(DNXHDContext *ctx, AVFrame *frame, int x, int dest_u = frame-data[1] + ((y * dct_linesize_chroma) 4) + (x (3 + shift1 + ctx-is_444)); dest_v = frame-data[2] + ((y * dct_linesize_chroma) 4) + (x (3 + shift1 + ctx-is_444)); -if (ctx-cur_field) { +if (frame-interlaced_frame ctx-cur_field) { dest_y += frame-linesize[0]; dest_u += frame-linesize[1]; dest_v += frame-linesize[2]; ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avformat/mov: Disallow .. in dref unless use_absolute_path is set
ffmpeg | branch: release/2.2 | Michael Niedermayer michae...@gmx.at | Sat Mar 14 21:32:35 2015 +0100| [0bcb669eccba63433f5e7fa0a2ca4b7bddab15ef] | committer: Michael Niedermayer avformat/mov: Disallow .. in dref unless use_absolute_path is set as this kind of allows to circumvent it to some extend. We also could add a separate parameter or value to choose this Found-by: ramiro Signed-off-by: Michael Niedermayer michae...@gmx.at (cherry picked from commit 1e4d0498df6621143da1a550006ddc3526ad51cb) Signed-off-by: Michael Niedermayer michae...@gmx.at http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=0bcb669eccba63433f5e7fa0a2ca4b7bddab15ef --- libavformat/mov.c |3 +++ 1 file changed, 3 insertions(+) diff --git a/libavformat/mov.c b/libavformat/mov.c index 1243c35..5b4986c 100644 --- a/libavformat/mov.c +++ b/libavformat/mov.c @@ -2345,6 +2345,9 @@ static int mov_open_dref(AVIOContext **pb, const char *src, MOVDref *ref, av_strlcat(filename, ../, sizeof(filename)); av_strlcat(filename, ref-path + l + 1, sizeof(filename)); +if (!use_absolute_path) +if(strstr(ref-path + l + 1, ..) || ref-nlvl_from 1) +return AVERROR(ENOENT); if (strlen(filename) + 1 == sizeof(filename)) return AVERROR(ENOENT); ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] ffmpeg: Fix extradata allocation
ffmpeg | branch: release/2.2 | Michael Niedermayer michae...@gmx.at | Fri Apr 3 23:44:38 2015 +0200| [e63f330a1c3c0644aaec4a66c14cdacd6bf28141] | committer: Michael Niedermayer ffmpeg: Fix extradata allocation Signed-off-by: Michael Niedermayer michae...@gmx.at (cherry picked from commit 4d02dfbde475d249916eb19c360e890059aa6aa5) Conflicts: ffmpeg.c http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=e63f330a1c3c0644aaec4a66c14cdacd6bf28141 --- ffmpeg.c | 10 ++ 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/ffmpeg.c b/ffmpeg.c index d566773..0fab24a 100644 --- a/ffmpeg.c +++ b/ffmpeg.c @@ -2382,11 +2382,13 @@ static int transcode_init(void) codec-rc_max_rate= icodec-rc_max_rate; codec-rc_buffer_size = icodec-rc_buffer_size; codec-field_order= icodec-field_order; -codec-extradata = av_mallocz(extra_size); -if (!codec-extradata) { -return AVERROR(ENOMEM); +if (icodec-extradata_size) { +codec-extradata = av_mallocz(extra_size); +if (!codec-extradata) { +return AVERROR(ENOMEM); +} +memcpy(codec-extradata, icodec-extradata, icodec-extradata_size); } -memcpy(codec-extradata, icodec-extradata, icodec-extradata_size); codec-extradata_size= icodec-extradata_size; codec-bits_per_coded_sample = icodec-bits_per_coded_sample; ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avutil/pca: Check for av_malloc* failures
ffmpeg | branch: release/2.2 | Michael Niedermayer michae...@gmx.at | Mon Mar 30 04:37:42 2015 +0200| [c701506525b3e5585567303270a12d844f38c264] | committer: Michael Niedermayer avutil/pca: Check for av_malloc* failures Signed-off-by: Michael Niedermayer michae...@gmx.at (cherry picked from commit dadc43eee4d9036aa532665a04720238cc15e922) Signed-off-by: Michael Niedermayer michae...@gmx.at http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=c701506525b3e5585567303270a12d844f38c264 --- libavutil/pca.c |8 1 file changed, 8 insertions(+) diff --git a/libavutil/pca.c b/libavutil/pca.c index 311b6bc..a745136 100644 --- a/libavutil/pca.c +++ b/libavutil/pca.c @@ -41,12 +41,20 @@ PCA *ff_pca_init(int n){ return NULL; pca= av_mallocz(sizeof(*pca)); +if (!pca) +return NULL; + pca-n= n; pca-z = av_malloc(sizeof(*pca-z) * n); pca-count=0; pca-covariance= av_calloc(n*n, sizeof(double)); pca-mean= av_calloc(n, sizeof(double)); +if (!pca-z || !pca-covariance || !pca-mean) { +ff_pca_free(pca); +return NULL; +} + return pca; } ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avcodec/h264: Fail for invalid mixed IDR / non IDR frames in slice threading mode
ffmpeg | branch: release/2.2 | Michael Niedermayer michae...@gmx.at | Sat Apr 4 19:28:33 2015 +0200| [5b4e58ed4c3641a934b46b6e3063b4b2d5fc8bed] | committer: Michael Niedermayer avcodec/h264: Fail for invalid mixed IDR / non IDR frames in slice threading mode Fixes Ticket4408 Signed-off-by: Michael Niedermayer michae...@gmx.at (cherry picked from commit fc58d5c43b4c7396fc69081eb0dfe5b6a21cb10d) Signed-off-by: Michael Niedermayer michae...@gmx.at http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=5b4e58ed4c3641a934b46b6e3063b4b2d5fc8bed --- libavcodec/h264.c |8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/libavcodec/h264.c b/libavcodec/h264.c index 56858f4..155877b 100644 --- a/libavcodec/h264.c +++ b/libavcodec/h264.c @@ -5006,8 +5006,14 @@ again: ret = -1; goto end; } -if(!idr_cleared) +if(!idr_cleared) { +if (h-current_slice (avctx-active_thread_type FF_THREAD_SLICE)) { +av_log(h, AV_LOG_ERROR, invalid mixed IDR / non IDR frames cannot be decoded in slice multithreading mode\n); +ret = AVERROR_INVALIDDATA; +goto end; +} idr(h); // FIXME ensure we don't lose some frames if there is reordering +} idr_cleared = 1; h-has_recovery_point = 1; case NAL_SLICE: ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] hevc: make the crop sizes unsigned
ffmpeg | branch: release/2.2 | Anton Khirnov an...@khirnov.net | Fri Mar 20 21:28:34 2015 +0100| [fdb8a35b0267ada917edd56e424acacd9511cff6] | committer: Michael Niedermayer hevc: make the crop sizes unsigned (cherry picked from commit c929659bdd7d2d5848ea52e685a3164c7b901bb0) Signed-off-by: Michael Niedermayer michae...@gmx.at http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=fdb8a35b0267ada917edd56e424acacd9511cff6 --- libavcodec/hevc.h |8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/libavcodec/hevc.h b/libavcodec/hevc.h index 3d71871..faedeb2 100644 --- a/libavcodec/hevc.h +++ b/libavcodec/hevc.h @@ -283,10 +283,10 @@ typedef struct RefPicListTab { } RefPicListTab; typedef struct HEVCWindow { -int left_offset; -int right_offset; -int top_offset; -int bottom_offset; +unsigned int left_offset; +unsigned int right_offset; +unsigned int top_offset; +unsigned int bottom_offset; } HEVCWindow; typedef struct VUI { ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avcodec/hevc_ps: Check cropping parameters more correctly
ffmpeg | branch: release/2.2 | Michael Niedermayer michae...@gmx.at | Sat Mar 21 12:54:16 2015 +0100| [691dbc628a43dca2f610ee8dfd448766e435c107] | committer: Michael Niedermayer avcodec/hevc_ps: Check cropping parameters more correctly Signed-off-by: Michael Niedermayer michae...@gmx.at (cherry picked from commit 06c70d45373dedc600f28e345685b130b60203c1) Signed-off-by: Michael Niedermayer michae...@gmx.at http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=691dbc628a43dca2f610ee8dfd448766e435c107 --- libavcodec/hevc_ps.c |3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libavcodec/hevc_ps.c b/libavcodec/hevc_ps.c index aa9153f..2dad58d 100644 --- a/libavcodec/hevc_ps.c +++ b/libavcodec/hevc_ps.c @@ -898,7 +898,8 @@ int ff_hevc_decode_nal_sps(HEVCContext *s) (sps-output_window.left_offset + sps-output_window.right_offset); sps-output_height = sps-height - (sps-output_window.top_offset + sps-output_window.bottom_offset); -if (sps-output_width = 0 || sps-output_height = 0) { +if (sps-width = sps-output_window.left_offset + (int64_t)sps-output_window.right_offset || +sps-height = sps-output_window.top_offset + (int64_t)sps-output_window.bottom_offset) { av_log(s-avctx, AV_LOG_WARNING, Invalid visible frame dimensions: %dx%d.\n, sps-output_width, sps-output_height); if (s-avctx-err_recognition AV_EF_EXPLODE) { ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] lavf: Add support for WebM Live Muxing
ffmpeg | branch: master | Vignesh Venkatasubramanian vigne...@google.com | Mon Mar 30 14:46:10 2015 -0700| [6fd300ac6c2c3871736ce0e6df95603255004dc6] | committer: Michael Niedermayer lavf: Add support for WebM Live Muxing This patch adds support for WebM Live Muxing by adding a new WebM Chunk muxer. It writes out live WebM Chunks which can be used for playback using Live DASH Clients. Please see muxers.texi for sample usage. Signed-off-by: Vignesh Venkatasubramanian vigne...@google.com Signed-off-by: Michael Niedermayer michae...@gmx.at http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=6fd300ac6c2c3871736ce0e6df95603255004dc6 --- Changelog |1 + doc/muxers.texi | 43 libavformat/Makefile |5 +- libavformat/allformats.c |1 + libavformat/matroskaenc.c | 12 ++- libavformat/version.h |2 +- libavformat/webm_chunk.c | 262 + 7 files changed, 320 insertions(+), 6 deletions(-) diff --git a/Changelog b/Changelog index a6a0e2d..4f48261 100644 --- a/Changelog +++ b/Changelog @@ -14,6 +14,7 @@ version next: - MMAL-accelerated H.264 decoding - basic APNG encoder and muxer - unpack DivX-style packed B-frames in MPEG-4 bitstream filter +- WebM Live Chunk Muxer version 2.6: diff --git a/doc/muxers.texi b/doc/muxers.texi index f0ca730..335f093 100644 --- a/doc/muxers.texi +++ b/doc/muxers.texi @@ -1268,4 +1268,47 @@ ffmpeg -f webm_dash_manifest -i video1.webm \ manifest.xml @end example +@section webm_chunk + +WebM Live Chunk Muxer. + +This muxer writes out WebM headers and chunks as separate files which can be +consumed by clients that support WebM Live streams via DASH. + +@subsection Options + +This muxer supports the following options: + +@table @option +@item chunk_start_index +Index of the first chunk (defaults to 0). + +@item header +Filename of the header where the initialization data will be written. + +@item audio_chunk_duration +Duration of each audio chunk in milliseconds (defaults to 5000). +@end table + +@subsection Example +@example +ffmpeg -f v4l2 -i /dev/video0 \ + -f alsa -i hw:0 \ + -map 0:0 \ + -c:v libvpx-vp9 \ + -s 640x360 -keyint_min 30 -g 30 \ + -f webm_chunk \ + -header webm_live_video_360.hdr \ + -chunk_start_index 1 \ + webm_live_video_360_%d.chk \ + -map 1:0 \ + -c:a libvorbis \ + -b:a 128k \ + -f webm_chunk \ + -header webm_live_audio_128.hdr \ + -chunk_start_index 1 \ + -audio_chunk_duration 1000 \ + webm_live_audio_128_%d.chk +@end example + @c man end MUXERS diff --git a/libavformat/Makefile b/libavformat/Makefile index 5082101..8d9a770 100644 --- a/libavformat/Makefile +++ b/libavformat/Makefile @@ -238,7 +238,7 @@ OBJS-$(CONFIG_MATROSKA_DEMUXER) += matroskadec.o matroska.o \ OBJS-$(CONFIG_MATROSKA_MUXER)+= matroskaenc.o matroska.o \ isom.o avc.o hevc.o \ flacenc_header.o avlanguage.o vorbiscomment.o wv.o \ -webmdashenc.o +webmdashenc.o webm_chunk.o OBJS-$(CONFIG_MD5_MUXER) += md5enc.o OBJS-$(CONFIG_MGSTS_DEMUXER) += mgsts.o OBJS-$(CONFIG_MICRODVD_DEMUXER) += microdvddec.o subtitles.o @@ -452,12 +452,13 @@ OBJS-$(CONFIG_WEBM_MUXER)+= matroskaenc.o matroska.o \ isom.o avc.o hevc.o \ flacenc_header.o avlanguage.o \ wv.o vorbiscomment.o \ -webmdashenc.o +webmdashenc.o webm_chunk.o OBJS-$(CONFIG_WEBM_DASH_MANIFEST_DEMUXER)+= matroskadec.o matroska.o \ isom.o rmsipr.o flac_picture.o \ oggparsevorbis.o vorbiscomment.o \ flac_picture.o replaygain.o OBJS-$(CONFIG_WEBM_DASH_MANIFEST_MUXER) += webmdashenc.o matroska.o +OBJS-$(CONFIG_WEBM_CHUNK_MUXER) += webm_chunk.o matroska.o OBJS-$(CONFIG_WEBP_MUXER)+= webpenc.o OBJS-$(CONFIG_WEBVTT_DEMUXER)+= webvttdec.o subtitles.o OBJS-$(CONFIG_WEBVTT_MUXER) += webvttenc.o diff --git a/libavformat/allformats.c b/libavformat/allformats.c index ca45db8..e6a9d01 100644 --- a/libavformat/allformats.c +++ b/libavformat/allformats.c @@ -316,6 +316,7 @@ void av_register_all(void) REGISTER_DEMUXER (WC3, wc3); REGISTER_MUXER (WEBM, webm); REGISTER_MUXDEMUX(WEBM_DASH_MANIFEST, webm_dash_manifest); +REGISTER_MUXER (WEBM_CHUNK, webm_chunk); REGISTER_MUXER (WEBP, webp);
[FFmpeg-cvslog] Merge commit '108f2f381acb93827fb4add0517eeae859afa3bf'
ffmpeg | branch: master | Michael Niedermayer michae...@gmx.at | Tue Apr 7 19:58:31 2015 +0200| [0739179bfb002324eea20f1c44c5f586b6bd3e04] | committer: Michael Niedermayer Merge commit '108f2f381acb93827fb4add0517eeae859afa3bf' * commit '108f2f381acb93827fb4add0517eeae859afa3bf': parseutils: Extend small_strptime to be used in avformat Conflicts: libavutil/parseutils.c Merged-by: Michael Niedermayer michae...@gmx.at http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=0739179bfb002324eea20f1c44c5f586b6bd3e04 --- ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] parseutils: Extend small_strptime to be used in avformat
ffmpeg | branch: master | Luca Barbato lu_z...@gentoo.org | Mon Apr 6 01:25:52 2015 +0200| [108f2f381acb93827fb4add0517eeae859afa3bf] | committer: Luca Barbato parseutils: Extend small_strptime to be used in avformat The strptime implementation is supposed to support whitespace and %T. http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=108f2f381acb93827fb4add0517eeae859afa3bf --- libavutil/parseutils.c | 108 ++-- 1 file changed, 58 insertions(+), 50 deletions(-) diff --git a/libavutil/parseutils.c b/libavutil/parseutils.c index 4ae47ee..0e07b4a 100644 --- a/libavutil/parseutils.c +++ b/libavutil/parseutils.c @@ -404,61 +404,69 @@ static const char *small_strptime(const char *p, const char *fmt, struct tm *dt) { int c, val; -for(;;) { +while((c = *fmt++)) { +if (c != '%') { +if (av_isspace(c)) +for (; *p av_isspace(*p); p++); +else if (*p != c) +return NULL; +else p++; +continue; +} + c = *fmt++; -if (c == '\0') { -return p; -} else if (c == '%') { -c = *fmt++; -switch(c) { -case 'H': -val = date_get_num(p, 0, 23, 2); -if (val == -1) -return NULL; -dt-tm_hour = val; -break; -case 'M': -val = date_get_num(p, 0, 59, 2); -if (val == -1) -return NULL; -dt-tm_min = val; -break; -case 'S': -val = date_get_num(p, 0, 59, 2); -if (val == -1) -return NULL; -dt-tm_sec = val; -break; -case 'Y': -val = date_get_num(p, 0, , 4); -if (val == -1) -return NULL; -dt-tm_year = val - 1900; -break; -case 'm': -val = date_get_num(p, 1, 12, 2); -if (val == -1) -return NULL; -dt-tm_mon = val - 1; -break; -case 'd': -val = date_get_num(p, 1, 31, 2); -if (val == -1) -return NULL; -dt-tm_mday = val; -break; -case '%': -goto match; -default: +switch(c) { +case 'H': +val = date_get_num(p, 0, 23, 2); +if (val == -1) return NULL; -} -} else { -match: -if (c != *p) +dt-tm_hour = val; +break; +case 'M': +val = date_get_num(p, 0, 59, 2); +if (val == -1) return NULL; -p++; +dt-tm_min = val; +break; +case 'S': +val = date_get_num(p, 0, 59, 2); +if (val == -1) +return NULL; +dt-tm_sec = val; +break; +case 'Y': +val = date_get_num(p, 0, , 4); +if (val == -1) +return NULL; +dt-tm_year = val - 1900; +break; +case 'm': +val = date_get_num(p, 1, 12, 2); +if (val == -1) +return NULL; +dt-tm_mon = val - 1; +break; +case 'd': +val = date_get_num(p, 1, 31, 2); +if (val == -1) +return NULL; +dt-tm_mday = val; +break; +case 'T': +p = small_strptime(p, %H:%M:%S, dt); +if (!p) +return NULL; +break; +case '%': +if (*p++ != '%') +return NULL; +break; +default: +return NULL; } } + +return p; } time_t av_timegm(struct tm *tm) ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] Merge commit '27f274628234c1f934b9a6a6380ed567c1b4ceae'
ffmpeg | branch: master | Michael Niedermayer michae...@gmx.at | Tue Apr 7 20:34:24 2015 +0200| [9c37c81246146ef45bba59546cc611a6e26a5b21] | committer: Michael Niedermayer Merge commit '27f274628234c1f934b9a6a6380ed567c1b4ceae' * commit '27f274628234c1f934b9a6a6380ed567c1b4ceae': parseutils: Make av_small_strptime public Conflicts: doc/APIchanges libavformat/utils.c libavutil/parseutils.c libavutil/version.h See: 29e972f67c914d35417bc7368493d2617abdd26e Merged-by: Michael Niedermayer michae...@gmx.at http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=9c37c81246146ef45bba59546cc611a6e26a5b21 --- ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] parseutils: Make av_small_strptime public
ffmpeg | branch: master | Luca Barbato lu_z...@gentoo.org | Mon Apr 6 01:45:37 2015 +0200| [27f274628234c1f934b9a6a6380ed567c1b4ceae] | committer: Luca Barbato parseutils: Make av_small_strptime public And use it in libavformat. Based on a similar patch by Stefano Sabatini stefa...@gmail.com. http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=27f274628234c1f934b9a6a6380ed567c1b4ceae --- configure |2 -- doc/APIchanges |3 +++ libavformat/utils.c| 11 ++- libavutil/parseutils.c | 10 +- libavutil/parseutils.h | 31 +++ libavutil/version.h|2 +- 6 files changed, 42 insertions(+), 17 deletions(-) diff --git a/configure b/configure index 6ad813b..8821cbc 100755 --- a/configure +++ b/configure @@ -1487,7 +1487,6 @@ SYSTEM_FUNCS= setrlimit Sleep strerror_r -strptime sysconf sysctl usleep @@ -4133,7 +4132,6 @@ check_func_headers time.h nanosleep || { check_func_headers time.h nanosleep -lr check_func sched_getaffinity check_func setrlimit check_func strerror_r -check_func strptime check_func sysconf check_func sysctl check_func usleep diff --git a/doc/APIchanges b/doc/APIchanges index 75eb66b..35830f8 100644 --- a/doc/APIchanges +++ b/doc/APIchanges @@ -13,6 +13,9 @@ libavutil: 2014-08-09 API changes, most recent first: +2015-xx-xx - xxx - lavu 54.11.0 + Add av_small_strptime(). + 2015-xx-xx - xxx - lavc 56.22.0 Add FF_PROFILE_DTS_EXPRESS. diff --git a/libavformat/utils.c b/libavformat/utils.c index 6248c1e..c275d06 100644 --- a/libavformat/utils.c +++ b/libavformat/utils.c @@ -2902,21 +2902,14 @@ int ff_find_stream_index(AVFormatContext *s, int id) int64_t ff_iso8601_to_unix_time(const char *datestr) { -#if HAVE_STRPTIME struct tm time1 = { 0 }, time2 = { 0 }; char *ret1, *ret2; -ret1 = strptime(datestr, %Y - %m - %d %T, time1); -ret2 = strptime(datestr, %Y - %m - %dT%T, time2); +ret1 = av_small_strptime(datestr, %Y - %m - %d %T, time1); +ret2 = av_small_strptime(datestr, %Y - %m - %dT%T, time2); if (ret2 !ret1) return av_timegm(time2); else return av_timegm(time1); -#else -av_log(NULL, AV_LOG_WARNING, - strptime() unavailable on this system, cannot convert - the date string.\n); -return 0; -#endif } int avformat_query_codec(const AVOutputFormat *ofmt, enum AVCodecID codec_id, diff --git a/libavutil/parseutils.c b/libavutil/parseutils.c index 0e07b4a..be238f0 100644 --- a/libavutil/parseutils.c +++ b/libavutil/parseutils.c @@ -400,7 +400,7 @@ static int date_get_num(const char **pp, return val; } -static const char *small_strptime(const char *p, const char *fmt, struct tm *dt) +const char *av_small_strptime(const char *p, const char *fmt, struct tm *dt) { int c, val; @@ -453,7 +453,7 @@ static const char *small_strptime(const char *p, const char *fmt, struct tm *dt) dt-tm_mday = val; break; case 'T': -p = small_strptime(p, %H:%M:%S, dt); +p = av_small_strptime(p, %H:%M:%S, dt); if (!p) return NULL; break; @@ -526,7 +526,7 @@ int av_parse_time(int64_t *timeval, const char *timestr, int duration) /* parse the year-month-day part */ for (i = 0; i FF_ARRAY_ELEMS(date_fmt); i++) { -q = small_strptime(p, date_fmt[i], dt); +q = av_small_strptime(p, date_fmt[i], dt); if (q) { break; } @@ -550,7 +550,7 @@ int av_parse_time(int64_t *timeval, const char *timestr, int duration) /* parse the hour-minute-second part */ for (i = 0; i FF_ARRAY_ELEMS(time_fmt); i++) { -q = small_strptime(p, time_fmt[i], dt); +q = av_small_strptime(p, time_fmt[i], dt); if (q) { break; } @@ -562,7 +562,7 @@ int av_parse_time(int64_t *timeval, const char *timestr, int duration) ++p; } /* parse timestr as HH:MM:SS */ -q = small_strptime(p, time_fmt[0], dt); +q = av_small_strptime(p, time_fmt[0], dt); if (!q) { char *o; /* parse timestr as S+ */ diff --git a/libavutil/parseutils.h b/libavutil/parseutils.h index 0844abb..8e99634 100644 --- a/libavutil/parseutils.h +++ b/libavutil/parseutils.h @@ -117,6 +117,37 @@ int av_parse_time(int64_t *timeval, const char *timestr, int duration); int av_find_info_tag(char *arg, int arg_size, const char *tag1, const char *info); /** + * Simplified version of strptime + * + * Parse the input string p according to the format string fmt and + * store its results in the structure dt. + * + * Neither text and locale's alternative representation are supported. + * + * The supported input field descriptors are listed below. + * - %H: the hour as a decimal number, using a
[FFmpeg-cvslog] avformat/asfenc: Check for index_ptr allocation failure
ffmpeg | branch: master | Michael Niedermayer michae...@gmx.at | Tue Apr 7 22:29:54 2015 +0200| [3662e251cbe0edc05cd03349a606a06f3bb96eda] | committer: Michael Niedermayer avformat/asfenc: Check for index_ptr allocation failure Signed-off-by: Michael Niedermayer michae...@gmx.at http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=3662e251cbe0edc05cd03349a606a06f3bb96eda --- libavformat/asfenc.c |2 ++ 1 file changed, 2 insertions(+) diff --git a/libavformat/asfenc.c b/libavformat/asfenc.c index 5e0f7b0..015c731 100644 --- a/libavformat/asfenc.c +++ b/libavformat/asfenc.c @@ -652,6 +652,8 @@ static int asf_write_header(AVFormatContext *s) asf-nb_packets = 0; asf-index_ptr = av_malloc(sizeof(ASFIndex) * ASF_INDEX_BLOCK); +if (!asf-index_ptr) +return AVERROR(ENOMEM); asf-nb_index_memory_alloc = ASF_INDEX_BLOCK; asf-maximum_packet= 0; ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] webmdashenc: Fix fate in MSVC
ffmpeg | branch: master | Vignesh Venkatasubramanian vigne...@google.com | Tue Apr 7 12:21:02 2015 -0700| [d6bb82387c1232a5e84650b979d46477fb9693db] | committer: Michael Niedermayer webmdashenc: Fix fate in MSVC MSVC does not support the %F and %T format specifiers in strftime. Replace that with the expanded version. This fixes the broken fate tests in MSVC (webm-dash-manifest-*). Signed-off-by: Vignesh Venkatasubramanian vigne...@google.com Signed-off-by: Michael Niedermayer michae...@gmx.at http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=d6bb82387c1232a5e84650b979d46477fb9693db --- libavformat/webmdashenc.c | 19 +-- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/libavformat/webmdashenc.c b/libavformat/webmdashenc.c index 37646de..c5347a9 100644 --- a/libavformat/webmdashenc.c +++ b/libavformat/webmdashenc.c @@ -91,9 +91,6 @@ static void write_header(AVFormatContext *s) { WebMDashMuxContext *w = s-priv_data; double min_buffer_time = 1.0; -time_t local_time; -struct tm *gmt, gmt_buffer; -char *gmt_iso = av_malloc(21); avio_printf(s-pb, ?xml version=\1.0\ encoding=\UTF-8\?\n); avio_printf(s-pb, MPD\n); avio_printf(s-pb, xmlns:xsi=\http://www.w3.org/2001/XMLSchema-instance\\n;); @@ -108,13 +105,15 @@ static void write_header(AVFormatContext *s) avio_printf(s-pb, profiles=\%s\%s, w-is_live ? urn:mpeg:dash:profile:isoff-live:2011 : urn:webm:dash:profile:webm-on-demand:2012, w-is_live ? \n : \n); -time(local_time); -gmt = gmtime_r(local_time, gmt_buffer); -strftime(gmt_iso, 21, %FT%TZ, gmt); -if (w-debug_mode) { -av_strlcpy(gmt_iso, , 1); -} if (w-is_live) { +time_t local_time = time(NULL); +struct tm gmt_buffer; +struct tm *gmt = gmtime_r(local_time, gmt_buffer); +char *gmt_iso = av_malloc(21); +strftime(gmt_iso, 21, %Y-%m-%dT%H:%M:%SZ, gmt); +if (w-debug_mode) { +av_strlcpy(gmt_iso, , 1); +} avio_printf(s-pb, availabilityStartTime=\%s\\n, gmt_iso); avio_printf(s-pb, timeShiftBufferDepth=\PT%gS\, w-time_shift_buffer_depth); avio_printf(s-pb, \n); @@ -123,8 +122,8 @@ static void write_header(AVFormatContext *s) w-utc_timing_url ? urn:mpeg:dash:utc:http-iso:2014 : urn:mpeg:dash:utc:direct:2012); avio_printf(s-pb, value=\%s\/\n, w-utc_timing_url ? w-utc_timing_url : gmt_iso); +av_free(gmt_iso); } -av_free(gmt_iso); } static void write_footer(AVFormatContext *s) ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avformat/ape: Use av_malloc_array()
ffmpeg | branch: master | Michael Niedermayer michae...@gmx.at | Tue Apr 7 22:50:07 2015 +0200| [f289422a3ea53db13f6072b5ae97e6fa2e3b7b09] | committer: Michael Niedermayer avformat/ape: Use av_malloc_array() Signed-off-by: Michael Niedermayer michae...@gmx.at http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=f289422a3ea53db13f6072b5ae97e6fa2e3b7b09 --- libavformat/ape.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/ape.c b/libavformat/ape.c index 28f73d3..69b001a 100644 --- a/libavformat/ape.c +++ b/libavformat/ape.c @@ -268,7 +268,7 @@ static int ape_read_header(AVFormatContext * s) ape-seektablelength / sizeof(*ape-seektable), ape-totalframes); return AVERROR_INVALIDDATA; } -ape-frames = av_malloc(ape-totalframes * sizeof(APEFrame)); +ape-frames = av_malloc_array(ape-totalframes, sizeof(APEFrame)); if(!ape-frames) return AVERROR(ENOMEM); ape-firstframe = ape-junklength + ape-descriptorlength + ape-headerlength + ape-seektablelength + ape-wavheaderlength; ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avformat/segment: Change enum to int, which is accessed via AVOption as int
ffmpeg | branch: master | Michael Niedermayer michae...@gmx.at | Tue Apr 7 23:21:48 2015 +0200| [235589ee9e9adfe2eca517fdd6239e975a5ba2c6] | committer: Michael Niedermayer avformat/segment: Change enum to int, which is accessed via AVOption as int This fixes depending on implementation defined behavior Signed-off-by: Michael Niedermayer michae...@gmx.at http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=235589ee9e9adfe2eca517fdd6239e975a5ba2c6 --- libavformat/segment.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/segment.c b/libavformat/segment.c index 69038ca..1162ea2 100644 --- a/libavformat/segment.c +++ b/libavformat/segment.c @@ -86,7 +86,7 @@ typedef struct SegmentContext { int cut_pending; char *entry_prefix;/// prefix to add to list entry filenames -ListType list_type;/// set the list type +int list_type; /// set the list type AVIOContext *list_pb; /// list file put-byte context char *time_str;/// segment duration specification string int64_t time; /// segment duration ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog