aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/avcodec.h
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2017-05-11 13:01:36 +0200
committerMichael Niedermayer <michael@niedermayer.cc>2017-05-14 12:20:16 +0200
commit9c6577035e4f33156b310bffdcc13bc44666191d (patch)
tree94a35f2f560073cb97ad9f28ca43a892fba0b14e /libavcodec/avcodec.h
parent7d37865af0ff6d2806866753a3390c557c373b2b (diff)
downloadffmpeg-9c6577035e4f33156b310bffdcc13bc44666191d.tar.gz
avcodec/avcodec: Limit the number of side data elements per packet
Fixes: 1293/clusterfuzz-testcase-minimized-6054752074858496 See: [FFmpeg-devel] [PATCH] avcodec/avcodec: Limit the number of side data elements per packet Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> (cherry picked from commit d5711cb89121268e8d78ebe8563a68e67a236cbb) Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavcodec/avcodec.h')
-rw-r--r--libavcodec/avcodec.h12
1 files changed, 11 insertions, 1 deletions
diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h
index e5e7f4225d..10068db14b 100644
--- a/libavcodec/avcodec.h
+++ b/libavcodec/avcodec.h
@@ -1536,7 +1536,17 @@ enum AVPacketSideDataType {
* should be associated with a video stream and containts data in the form
* of the AVMasteringDisplayMetadata struct.
*/
- AV_PKT_DATA_MASTERING_DISPLAY_METADATA
+ AV_PKT_DATA_MASTERING_DISPLAY_METADATA,
+
+ /**
+ * The number of side data elements (in fact a bit more than it).
+ * This is not part of the public API/ABI in the sense that it may
+ * change when new side data types are added.
+ * This must stay the last enum value.
+ * If its value becomes huge, some code using it
+ * needs to be updated as it assumes it to be smaller than other limits.
+ */
+ AV_PKT_DATA_NB
};
#define AV_PKT_DATA_QUALITY_FACTOR AV_PKT_DATA_QUALITY_STATS //DEPRECATED