summaryrefslogtreecommitdiff
path: root/libavcodec/h264.c
diff options
context:
space:
mode:
Diffstat (limited to 'libavcodec/h264.c')
-rw-r--r--libavcodec/h264.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/h264.c b/libavcodec/h264.c
index e1fcb62a7b..276d6e6d6c 100644
--- a/libavcodec/h264.c
+++ b/libavcodec/h264.c
@@ -995,7 +995,7 @@ int ff_h264_decode_extradata(H264Context *h)
cnt = *(p++); // Number of pps
for (i = 0; i < cnt; i++) {
nalsize = AV_RB16(p) + 2;
- if(decode_nal_units(h, p, nalsize) != nalsize) {
+ if (decode_nal_units(h, p, nalsize) < 0) {
av_log(avctx, AV_LOG_ERROR, "Decoding pps %d from avcC failed\n", i);
return -1;
}