From 645f705d6ac157ff29bbc45b7591d3a2f70b0b7f Mon Sep 17 00:00:00 2001 From: Andreas Rheinhardt Date: Sat, 20 Nov 2021 16:19:15 +0100 Subject: av(codec|device): Don't cast pointers to int C99/C11 6.3.2.3 5: "Any pointer type may be converted to an integer type. [...] If the result cannot be represented in the integer type, the behavior is undefined." So stop casting pointers to int; use uintptr_t instead. Reviewed-by: Michael Niedermayer Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/mpegvideoenc_template.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'libavcodec/x86/mpegvideoenc_template.c') diff --git a/libavcodec/x86/mpegvideoenc_template.c b/libavcodec/x86/mpegvideoenc_template.c index b32b1b0350..30c06a6b2c 100644 --- a/libavcodec/x86/mpegvideoenc_template.c +++ b/libavcodec/x86/mpegvideoenc_template.c @@ -109,7 +109,7 @@ static int RENAME(dct_quantize)(MpegEncContext *s, const uint16_t *qmat, *bias; LOCAL_ALIGNED_16(int16_t, temp_block, [64]); - av_assert2((7&(int)(&temp_block[0])) == 0); //did gcc align it correctly? + av_assert2((7&(uintptr_t)(&temp_block[0])) == 0); //did gcc align it correctly? //s->fdct (block); RENAME_FDCT(ff_fdct)(block); // cannot be anything else ... -- cgit v1.2.3