[FFmpeg-devel] [PATCH] fix VDPAU crash if get_buffer failed
Reimar Döffinger
Reimar.Doeffinger
Tue Feb 17 20:26:27 CET 2009
Hello,
since VDPAU "bypasses" the check in slice_end in mpeg12.c, it must check
itself if current_picture_ptr is valid, which is possible both for
broken files and if get_buffer failed.
Patch:
Index: libavcodec/vdpau.c
===================================================================
--- libavcodec/vdpau.c (revision 17395)
+++ libavcodec/vdpau.c (working copy)
@@ -184,6 +184,8 @@
struct vdpau_render_state *render, *last, *next;
int i;
+ if (!s->current_picture_ptr) return;
+
render = (struct vdpau_render_state *)s->current_picture_ptr->data[0];
assert(render);
More information about the ffmpeg-devel
mailing list