This email should have the patch. Sorry for the duplicate. When compiled by clang, libavcodec/videotoolboxenc.c produces three 'discards qualifiers' warnings. Changing type of nums[2] from void * to CFNumberRef silences the first two warnings. Adding a pointer (numsptr) to nums[2], and using that in CFArrayCreate silences the third warning.
Signed-off-by: Patrick Earnest <patr...@patrickearnest.com> --- libavcodec/videotoolboxenc.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/libavcodec/videotoolboxenc.c b/libavcodec/videotoolboxenc.c index 638f278cd0..4cc4fbfef4 100644 --- a/libavcodec/videotoolboxenc.c +++ b/libavcodec/videotoolboxenc.c @@ -904,7 +904,8 @@ static int vtenc_create_encoder(AVCodecContext *avctx, CFArrayRef data_rate_limits; int64_t bytes_per_second_value = 0; int64_t one_second_value = 0; - void *nums[2]; + CFNumberRef nums[2]; + void *numsptr = nums; int status = VTCompressionSessionCreate(kCFAllocatorDefault, avctx->width, @@ -962,7 +963,7 @@ static int vtenc_create_encoder(AVCodecContext *avctx, nums[0] = bytes_per_second; nums[1] = one_second; data_rate_limits = CFArrayCreate(kCFAllocatorDefault, - nums, + numsptr, 2, &kCFTypeArrayCallBacks); -- 2.11.0 (Apple Git-81) _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel