diff options
author | Martin Storsjö <martin@martin.st> | 2023-01-16 00:20:24 +0200 |
---|---|---|
committer | Martin Storsjö <martin@martin.st> | 2023-01-31 14:22:54 +0200 |
commit | 01f58f36465a13db069641cca47fa9777f03b875 (patch) | |
tree | 16e846dc4ae3b13132082ed2b2681ae490c302b3 /tests/ref/fate/filter-pixdesc-yuv422p16be | |
parent | 806ecace91d5b5e7c0f10b69746a57fd0d8a51f9 (diff) | |
download | ffmpeg-01f58f36465a13db069641cca47fa9777f03b875.tar.gz |
lavu/video_enc_params: Avoid relying on an undefined C construct
The construct of using offsetof on a (potentially anonymous) struct
defined within the offsetof expression, while supported by all
current compilers, has been declared explicitly undefined by the
C standards committee [1].
Clang recently got a change to identify this as an issue [2];
initially it was treated as a hard error, but it was soon after
softened into a warning under the -Wgnu-offsetof-extensions option
(not enabled automatically as part of -Wall though).
Nevertheless - in this particular case, it's trivial to fix the
code not to rely on the construct that the standards committee has
explicitly called out as undefined.
[1] https://www.open-std.org/jtc1/sc22/wg14/www/docs/n2350.htm
[2] https://reviews.llvm.org/D133574
Signed-off-by: Martin Storsjö <martin@martin.st>
Diffstat (limited to 'tests/ref/fate/filter-pixdesc-yuv422p16be')
0 files changed, 0 insertions, 0 deletions