[x265] Issue #480: Compiler warnings on x265 3.0 (multicoreware/x265)
flip -
issues-reply at bitbucket.org
Wed Mar 13 12:13:55 CET 2019
New issue 480: Compiler warnings on x265 3.0
https://bitbucket.org/multicoreware/x265/issues/480/compiler-warnings-on-x265-30
flip -:
During compilation of handbrake, the following warnings/hints appear:
```
CC src/libbluray/bdnav/libbluray_la-uo_mask.lo
/home/flip/programs/src/HandBrake/build/contrib/x265/x265_3.0/source/encoder/ratecontrol.cpp: In member function ‘int x265::RateControl::writeRateControlFrameStats(x265::Frame*, x265::RateControlEntry*)’:
/home/flip/programs/src/HandBrake/build/contrib/x265/x265_3.0/source/encoder/ratecontrol.cpp:2864:21: warning: passing argument 1 to restrict-qualified parameter aliases with argument 3 [-Wrestrict]
sprintf(deltaPOC, "%s%d~", deltaPOC, rpsWriter->deltaPOC[i]);
^~~~~~~~ ~~~~~~~~
/home/flip/programs/src/HandBrake/build/contrib/x265/x265_3.0/source/encoder/ratecontrol.cpp:2865:21: warning: passing argument 1 to restrict-qualified parameter aliases with argument 3 [-Wrestrict]
sprintf(bUsed, "%s%d~", bUsed, rpsWriter->bUsed[i]);
^~~~~ ~~~~~
CC src/libbluray/decoders/libbluray_la-graphics_controller.lo
CXX libAACdec/src/aacdec_hcr_bit.lo
CXX libAACdec/src/aacdec_hcrs.lo
/home/flip/programs/src/HandBrake/build/contrib/x265/x265_3.0/source/encoder/ratecontrol.cpp:2864:31: warning: ‘~’ directive writing 1 byte into a region of size between 0 and 127 [-Wformat-overflow=]
sprintf(deltaPOC, "%s%d~", deltaPOC, rpsWriter->deltaPOC[i]);
^~~~~~~
In file included from /usr/include/stdio.h:873,
from /usr/include/c++/8/cstdio:42,
from /home/flip/programs/src/HandBrake/build/contrib/x265/x265_3.0/source/common/common.h:33,
from /home/flip/programs/src/HandBrake/build/contrib/x265/x265_3.0/source/encoder/ratecontrol.cpp:30:
/usr/include/x86_64-linux-gnu/bits/stdio2.h:36:34: note: ‘__builtin___sprintf_chk’ output between 3 and 140 bytes into a destination of size 128
return __builtin___sprintf_chk (__s, __USE_FORTIFY_LEVEL - 1,
~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
__bos (__s), __fmt, __va_arg_pack ());
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/flip/programs/src/HandBrake/build/contrib/x265/x265_3.0/source/encoder/ratecontrol.cpp:2865:28: warning: ‘~’ directive writing 1 byte into a region of size between 0 and 39 [-Wformat-overflow=]
sprintf(bUsed, "%s%d~", bUsed, rpsWriter->bUsed[i]);
^~~~~~~
In file included from /usr/include/stdio.h:873,
from /usr/include/c++/8/cstdio:42,
from /home/flip/programs/src/HandBrake/build/contrib/x265/x265_3.0/source/common/common.h:33,
from /home/flip/programs/src/HandBrake/build/contrib/x265/x265_3.0/source/encoder/ratecontrol.cpp:30:
/usr/include/x86_64-linux-gnu/bits/stdio2.h:36:34: note: ‘__builtin___sprintf_chk’ output between 3 and 42 bytes into a destination of size 40
return __builtin___sprintf_chk (__s, __USE_FORTIFY_LEVEL - 1,
~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
__bos (__s), __fmt, __va_arg_pack ());
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
```
Probably related to
https://bitbucket.org/multicoreware/x265/issues/410/compiler-warnings
https://bitbucket.org/multicoreware/x265/issues/423/linux-build-error
But now it's half a year later so these are the "current" results.
More information about the x265-devel
mailing list