[vlc-devel] [PATCH 2/4] avcodec: va: assert sooner when the data are not right
Steve Lhomme
robux4 at videolabs.io
Tue Nov 29 14:19:36 CET 2016
---
modules/codec/avcodec/video.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/modules/codec/avcodec/video.c b/modules/codec/avcodec/video.c
index 699e6b3..0c70800 100644
--- a/modules/codec/avcodec/video.c
+++ b/modules/codec/avcodec/video.c
@@ -1126,6 +1126,7 @@ static int lavc_va_GetFrame(struct AVCodecContext *ctx, AVFrame *frame,
picture_Release(pic);
return -1;
}
+ assert(frame->data[0] != NULL);
/* data[0] must be non-NULL for libavcodec internal checks.
* data[3] actually contains the format-specific surface handle. */
frame->data[3] = frame->data[0];
@@ -1142,7 +1143,6 @@ static int lavc_va_GetFrame(struct AVCodecContext *ctx, AVFrame *frame,
}
frame->opaque = pic;
- assert(frame->data[0] != NULL);
return 0;
}
--
2.10.1
More information about the vlc-devel
mailing list